Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

fix($filter): change documentation of $filter to reflect optional com… #15371

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/ng/filter/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@
*
* The final result is an array of those elements that the predicate returned true for.
*
* @param {function(actual, expected)|true|undefined} comparator Comparator which is used in
* @param {function(actual, expected)|true|false} [comparator] Comparator which is used in
* determining if the expected value (from the filter expression) and actual value (from
* the object in the array) should be considered a match.
* the object in the array) should be considered a match.
*
* Can be one of:
*
Expand All @@ -54,13 +54,13 @@
* - `true`: A shorthand for `function(actual, expected) { return angular.equals(actual, expected)}`.
* This is essentially strict comparison of expected and actual.
*
* - `false|undefined`: A short hand for a function which will look for a substring match in case
* - `false`: A short hand for a function which will look for a substring match in case
* insensitive way.
*
* Primitive values are converted to strings. Objects are not compared against primitives,
* unless they have a custom `toString` method (e.g. `Date` objects).
* unless they have a custom `toString` method (e.g. `Date` objects). By default `false`.
*
* @param {string=} anyPropertyKey The special property name that matches against any property.
* @param {string=} [anyPropertyKey] The special property name that matches against any property.
* By default `$`.
*
* @example
Expand Down