Skip to content

Commit 313b566

Browse files
committed
bug #812 [make:auth] fix user email field with capital E (jrushlow)
This PR was merged into the 1.0-dev branch. Discussion ---------- [make:auth] fix user email field with capital `E` We were using the wrong `Str` camel case method to generate the username field variable for the authenticator template. ```diff // class ACustomAuthenticator extends AbstractLoginFormAuthenticator ... public function authenticate(Request $request): PassportInterface { - $Email = $request->request->get('email', ''); + $email = $request->request->get('email', ''); ... } ``` Commits ------- 8695026 lets use the correct camel case
2 parents 9a9e3f4 + 8695026 commit 313b566

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Maker/MakeAuthenticator.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ private function generateAuthenticatorClass(array $securityData, string $authent
283283
'user_class_name' => $userClassNameDetails->getShortName(),
284284
'username_field' => $userNameField,
285285
'username_field_label' => Str::asHumanWords($userNameField),
286-
'username_field_var' => Str::asCamelCase($userNameField),
286+
'username_field_var' => Str::asLowerCamelCase($userNameField),
287287
'user_needs_encoder' => $this->userClassHasEncoder($securityData, $userClass),
288288
'user_is_entity' => $this->doctrineHelper->isClassAMappedEntity($userClass),
289289
'provider_key_type_hint' => $this->providerKeyTypeHint(),

0 commit comments

Comments
 (0)