Skip to content

Commit

Permalink
[11.x] Set the value of $this in macro closures
Browse files Browse the repository at this point in the history
  • Loading branch information
simonwelsh authored May 13, 2024
1 parent 78e3dce commit 84fe512
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/Illuminate/Macroable/Traits/Macroable.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@ trait Macroable
/**
* Register a custom macro.
*
* @param string $name
* @param object|callable $macro
* @return void
* @param string $name
* @param object|callable $macro
* @param-closure-this static $macro
* @return void
*/
public static function macro($name, $macro)
{
Expand Down

0 comments on commit 84fe512

Please sign in to comment.