Skip to content

Commit 03be0af

Browse files
authored
Don't trim current_password (laravel#5546)
Inspired by laravel/framework#36415 As JetStream/Fortify uses a `current_password` field when allowing a user to change their password, and as JetStream is one of the starter kits listed on the docs, this PR adds `current_password` in the `$except` option of the `TrimStrings` middleware.
1 parent 16f531e commit 03be0af

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

app/Http/Middleware/TrimStrings.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ class TrimStrings extends Middleware
1212
* @var array
1313
*/
1414
protected $except = [
15+
'current_password',
1516
'password',
1617
'password_confirmation',
1718
];

0 commit comments

Comments
 (0)