public function getIdByUsername($username, array $params = [])
    {
        $arr = $this->listing(false, $params);
        if (!isset($arr[$username])) {
            return false;
        }

        return $arr[(string) $username];
    }
public function getIdByUsername($username, array $params = [])
    {
        $arr = $this->listing(false, $params);
        if (!isset($arr[$username])) {
            return false;
        }

        return $arr[(string) $username];
    }
public function getIdByUsername ( $ username , array $ params = [ ] ) { $ arr = $ this -> listing ( false , $ params ) ; if ( ! isset ( $ arr [ $ username ] ) ) { return false ; } return $ arr [ ( string ) $ username ] ; }
Get a user id given its username.

@param string $username
@param array  $params   to allow offset/limit (and more) to be passed

@return int|bool
Get a user id given its username .