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

Commit ba84467

Browse files
committed
Merge branch '2.7' into 2.8
* 2.7: [Yaml] throw a ParseException on invalid data type [TwigBridge] type-dependent path discovery Resources as string have the same problem Introduce failing test case when a SplFileInfo object is passed to the extract() method in the TwigExtractor. #15331 add infos about deprecated classes to UPGRADE-3.0 [Asset] removed unused private property. [Security] removed useless else condition in SwitchUserListener class. [travis] Tests deps=low with PHP 5.6 [Console] Fix console output with closed stdout
2 parents d9b548e + 30850d4 commit ba84467

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Http/Firewall/SwitchUserListener.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,9 +115,9 @@ private function attemptSwitchUser(Request $request)
115115
if (false !== $originalToken) {
116116
if ($token->getUsername() === $request->get($this->usernameParameter)) {
117117
return $token;
118-
} else {
119-
throw new \LogicException(sprintf('You are already switched to "%s" user.', $token->getUsername()));
120118
}
119+
120+
throw new \LogicException(sprintf('You are already switched to "%s" user.', $token->getUsername()));
121121
}
122122

123123
if (false === $this->accessDecisionManager->decide($token, array($this->role))) {

0 commit comments

Comments
 (0)