Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates docblock for duplicates collection method to correct its return type #53499

Merged
merged 1 commit into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
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
8 changes: 6 additions & 2 deletions src/Illuminate/Collections/Collection.php
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,9 @@ public function diffKeysUsing($items, callable $callback)
/**
* Retrieve duplicate items from the collection.
*
* @param (callable(TValue): bool)|string|null $callback
* @template TMapValue
*
* @param (callable(TValue): TMapValue)|string|null $callback
* @param bool $strict
* @return static
*/
Expand Down Expand Up @@ -335,7 +337,9 @@ public function duplicates($callback = null, $strict = false)
/**
* Retrieve duplicate items from the collection using strict comparison.
*
* @param (callable(TValue): bool)|string|null $callback
* @template TMapValue
*
* @param (callable(TValue): TMapValue)|string|null $callback
* @return static
*/
public function duplicatesStrict($callback = null)
Expand Down
8 changes: 6 additions & 2 deletions src/Illuminate/Collections/LazyCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,9 @@ public function diffKeysUsing($items, callable $callback)
/**
* Retrieve duplicate items.
*
* @param (callable(TValue): bool)|string|null $callback
* @template TMapValue
*
* @param (callable(TValue): TMapValue)|string|null $callback
* @param bool $strict
* @return static
*/
Expand All @@ -410,7 +412,9 @@ public function duplicates($callback = null, $strict = false)
/**
* Retrieve duplicate items using strict comparison.
*
* @param (callable(TValue): bool)|string|null $callback
* @template TMapValue
*
* @param (callable(TValue): TMapValue)|string|null $callback
* @return static
*/
public function duplicatesStrict($callback = null)
Expand Down
Loading