@@ -114,24 +114,21 @@ private function authenticateViaGuard(GuardAuthenticatorInterface $guardAuthenti
114114
115115 if (!$ user instanceof UserInterface) {
116116 throw new \UnexpectedValueException (sprintf (
117- 'The %s::getUser method must return a UserInterface. You returned %s. ' ,
117+ 'The %s::getUser() method must return a UserInterface. You returned %s. ' ,
118118 get_class ($ guardAuthenticator ),
119119 is_object ($ user ) ? get_class ($ user ) : gettype ($ user )
120120 ));
121121 }
122122
123- // check the preAuth UserChecker
124123 $ this ->userChecker ->checkPreAuth ($ user );
125- // check the credentials
126124 $ guardAuthenticator ->checkCredentials ($ token ->getCredentials (), $ user );
127- // check the postAuth UserChecker
128125 $ this ->userChecker ->checkPostAuth ($ user );
129126
130127 // turn the UserInterface into a TokenInterface
131128 $ authenticatedToken = $ guardAuthenticator ->createAuthenticatedToken ($ user , $ this ->providerKey );
132129 if (!$ authenticatedToken instanceof TokenInterface) {
133130 throw new \UnexpectedValueException (sprintf (
134- 'The %s::createAuthenticatedToken method must return a TokenInterface. You returned %s. ' ,
131+ 'The %s::createAuthenticatedToken() method must return a TokenInterface. You returned %s. ' ,
135132 get_class ($ guardAuthenticator ),
136133 is_object ($ authenticatedToken ) ? get_class ($ authenticatedToken ) : gettype ($ authenticatedToken )
137134 ));
0 commit comments