Skip to content

Commit

Permalink
Merge pull request #2467 from greg0ire/address-collections-18
Browse files Browse the repository at this point in the history
Address changes from doctrine/collections 1.8.0
  • Loading branch information
greg0ire authored Sep 29, 2022
2 parents 8e048f8 + 3d24c3d commit ebb5c10
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -359,6 +359,9 @@ public function containsKey($key)
return $this->coll->containsKey($key);
}

/**
* @template TMaybeContained
*/
public function contains($element)
{
$this->initialize();
Expand All @@ -373,6 +376,11 @@ public function exists(Closure $p)
return $this->coll->exists($p);
}

/**
* @psalm-return (TMaybeContained is T ? TKey|false : false)
*
* @template TMaybeContained
*/
public function indexOf($element)
{
$this->initialize();
Expand Down

0 comments on commit ebb5c10

Please sign in to comment.