protected function hasQueryBuilderMethod(string $name) : bool
    {
        if (method_exists($this->queryBuilder, $name)) {
            return true;
        }

        if (method_exists($this->queryBuilder, 'hasMacro') && $this->queryBuilder->hasMacro($name)) {
            return true;
        }

        return false;
    }
protected function hasQueryBuilderMethod(string $name) : bool
    {
        if (method_exists($this->queryBuilder, $name)) {
            return true;
        }

        if (method_exists($this->queryBuilder, 'hasMacro') && $this->queryBuilder->hasMacro($name)) {
            return true;
        }

        return false;
    }
protected function hasQueryBuilderMethod ( string $ name ) : bool { if ( method_exists ( $ this -> queryBuilder , $ name ) ) { return true ; } if ( method_exists ( $ this -> queryBuilder , 'hasMacro' ) && $ this -> queryBuilder -> hasMacro ( $ name ) ) { return true ; } return false ; }
Does the QueryBuilder we're using have a method with the provided name? This will also
check any functionality added via a macro.

@param  string  $name The method name
@return boolean
Does the QueryBuilder we re using have a method with the provided name? This will also check any functionality added via a macro .