Bug #23245 Bug Fixed

Incorrect doc block

Version: 3.5.11 Reporter: litzinger

     * Apply a filter
     * @param String  $property  Relationship.columnname
     * @param String  $operator  Comparison operator [default: ==]
     * @param Mixed   $value     Value to compare to
     * @return Query  $this
    public function filter($property, $operator, $value = FALSE)
     $this->addFilter($property, $operator, $value, 'and');
     return $this;

Several methods in the Builder class have the wrong @return value, thus PhpStorm is lighting up and unable to correctly type hint. The instances of @return Query should be @return Builder.

There is also several instances of @return Array, which should be @return array.

  • Incorrect: http://d.pr/i/ID0hgW

    Thus when trying to chain the filter method it indicates something is wrong: http://d.pr/i/tXPKNR

    Expected result: http://d.pr/i/Y7jXST

    10th October, 2017 at 10:17am
  • Thanks Brian,

    I’ve got a fix in for those (including a project search for return Array!).

    Robin Sowell
    24th October, 2017 at 7:53pm
  • Awesome, thanks!

    24th October, 2017 at 7:55pm

You must be signed in to comment on a bug report.

ExpressionEngine News

#eecms, #events, #releases