[8.x] Copy password rule to current_password #37650
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR does not contain breaking changes.
With the introduction of the new password rule we have to different rule under the same name:
password
rule: which validates the current passwordThis creates communication problems where the referenced rule can only be selected by the application context.
This PR moves the
password
validation tocurrent_password
and adds an alias to keep backwards compatibility. This allows:While not part of the PR, the main intention is to completely remove the
password
rule from the next major release (and maybe use it as an alias to Password::default() later in Laravel 10).If this PR accepted I will create others to add the necessary translation lines to the laravel/laravel repository and the necessary documentation update to laravel/docs.