Skip to content

Commit

Permalink
Accept any instance of Rule and not just Password (#37407)
Browse files Browse the repository at this point in the history
This would be useful if there a requirement to use custom Password implementation such as `Laravel\Fortify\Rules\Password` etc.
  • Loading branch information
crynobone authored May 19, 2021
1 parent 1996e69 commit 273d27f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Illuminate/Validation/Rules/Password.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public static function default()
{
$password = value(static::$defaultCallback);

return $password instanceof static ? $password : static::min(8);
return $password instanceof Rule ? $password : static::min(8);
}

/**
Expand Down

0 comments on commit 273d27f

Please sign in to comment.