Skip to content

Commit

Permalink
Add username and admin name on logout log
Browse files Browse the repository at this point in the history
  • Loading branch information
kiwi-commerce committed Jan 12, 2019
1 parent 6b4f4c6 commit ff8eff8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Plugin/Auth.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ public function __construct(
public function aroundLogout(\Magento\Backend\Model\Auth $auth, callable $proceed)
{
$this->benchmark->start(__METHOD__);
$result = $proceed();
if ($this->helper->isLoginEnable()) {
$user = $auth->getAuthStorage()->getUser();
$this->loginRepository->setUser($user)->addLogoutLog();
}
$result = $proceed();
$this->benchmark->end(__METHOD__);
return $result;
}
Expand Down

0 comments on commit ff8eff8

Please sign in to comment.