Skip to content
This repository was archived by the owner on May 31, 2024. It is now read-only.

Commit 3f8bd07

Browse files
committed
Merge branch '3.1'
* 3.1: [CS] Respect PSR2 4.2 [Form] fix `empty_data` option in expanded `ChoiceType` [Console] removed unneeded private methods updated Http-Kernel dependency [Security] [Guard] Improve comment with working example sync min email validator version [TwigBridge] Fix inconsistency in LintCommand help explicitly forbid e-mail validator 2.0 or higher Fixed SymfonyQuestionHelper multi-choice with defaults [DoctrineBridge] Don't use object IDs in DoctrineChoiceLoader when passing a value closure Differentiate between the first time a progress bar is displayed and subsequent times finished previous commit No more exception for malformed input name fix post_max_size_message translation [Process] Fix pipes cleaning on Windows Avoid phpunit 5.4 warnings on getMock [Form] Add exception to FormRenderer about non-unique block names [FrameworkBundle] templating can be fully disabled [Form] Consider a violation even if the form is not submitted
2 parents 7c2ac47 + 2e18864 commit 3f8bd07

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

Guard/GuardAuthenticatorInterface.php

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,15 @@ interface GuardAuthenticatorInterface extends AuthenticationEntryPointInterface
3939
* Whatever value you return here will be passed to getUser() and checkCredentials()
4040
*
4141
* For example, for a form login, you might:
42-
*
43-
* return array(
44-
* 'username' => $request->request->get('_username'),
45-
* 'password' => $request->request->get('_password'),
46-
* );
42+
*
43+
* if ($request->request->has('_username')) {
44+
* return array(
45+
* 'username' => $request->request->get('_username'),
46+
* 'password' => $request->request->get('_password'),
47+
* );
48+
* } else {
49+
* return;
50+
* }
4751
*
4852
* Or for an API token that's on a header, you might use:
4953
*

0 commit comments

Comments
 (0)