- Issue created by @cbuvaneswaran
- Status changed to Postponed: needs info
over 1 year ago 7:18am 21 August 2023 - 🇧🇪Belgium RandalV
Hi @cbuvaneswaran,
I've tested on several Drupal installs (9.5.10, 10.1.2, 9.3.3) and I cannot reproduce this issue.
The patch makes sense, but I don't understand in what situation this happens.
If you look at the MasqueradeRoleUser class (the class that overrides the default User Entity class), you'll see this:public function getRoles($exclude_locked_roles = FALSE) { if (!$this->roleManager()->isActive($this->id())) { return parent::getRoles($exclude_locked_roles); } $roles = $this->roleManager()->getRoles($this->id()); if ($exclude_locked_roles) { unset($roles[RoleInterface::ANONYMOUS_ID]); unset($roles[RoleInterface::AUTHENTICATED_ID]); } return $roles; }
This would mean that Masquerade Role is already active for the newly created account?
Could you test on a fresh 9.5.10 install and see if it happens there too? I have on a few fresh installs and it doesn't.If it does happen in a specific situation, could you please explain the exact steps to reproduce? Thanks!
- 🇧🇪Belgium RandalV
Well, I still don't see how Masquerade Role could be active on a new user so if you do figure that out please let me know, but I've pushed a change to the repo that should fix this issue if it does ever occur.
Thanks for reporting, I won't make a new release yet but if necessary you could use the 1.0.x branch.
- Status changed to Fixed
about 1 year ago 2:39pm 3 September 2023 Automatically closed - issue fixed for 2 weeks with no activity.