-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bugfix #122
Bugfix #122
Conversation
Thank you for you first contribution to this project. Could you elaborate a bit more which problem you fix with this PR? Is there any chance to add unit tests to cover the change? |
Plugin/AfterLoginPlugin.php
Outdated
@@ -55,11 +55,13 @@ class AfterLoginPlugin | |||
public function __construct( | |||
Session $session, | |||
ScopeConfigInterface $scopeConfig, | |||
$defaultTargetUrl | |||
$defaultTargetUrl, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is $defaultTargetUrl still needed? If I have seen correctly you are not using the variable any more at all. Or am I missing something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right. I missed that.
@@ -78,7 +78,7 @@ public function afterExecute(LoginPost $customerAccountLoginController, $resultR | |||
|
|||
$targetUrl = $this->session->getAfterLoginReferer(); | |||
if (empty($targetUrl)) { | |||
$targetUrl = $this->defaultTargetUrl; | |||
$targetUrl =$this->redirect->getRedirectUrl(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How is $this->redirect populated with the target url defined in Magento backend? Am I missing some magic here?
@webzellentOpenSource did you see my question regarding how |
@webzellentOpenSource would #117 fix this problem as well? |
@webzellentOpenSource is this still needed with #123 being solved? |
Sadly no feedback for quite a while. Will close the PR for now. |
Fix empty redirect to startpage on multi-website environment.