protected function resolveQueryFor(Builder $builder, string $filter) : Builder
    {
        $factory = $this->allowed[$filter];

        $input = $this->wantsByPrices($filter)
            ? $this->prices()
            : $this->request[$filter];

    	return (new $factory($input, $builder))->query();
    }
protected function resolveQueryFor(Builder $builder, string $filter) : Builder
    {
        $factory = $this->allowed[$filter];

        $input = $this->wantsByPrices($filter)
            ? $this->prices()
            : $this->request[$filter];

    	return (new $factory($input, $builder))->query();
    }
protected function resolveQueryFor ( Builder $ builder , string $ filter ) : Builder { $ factory = $ this -> allowed [ $ filter ] ; $ input = $ this -> wantsByPrices ( $ filter ) ? $ this -> prices ( ) : $ this -> request [ $ filter ] ; return ( new $ factory ( $ input , $ builder ) ) -> query ( ) ; }
Returns a query filtered by the given filter.

@param Builder $builder
@param string $key

@return Builder
Returns a query filtered by the given filter .