We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8fd41d2 commit b7180b2Copy full SHA for b7180b2
models/User.php
@@ -122,7 +122,7 @@ public function getIsAdmin()
122
{
123
return
124
(\Yii::$app->getAuthManager() && $this->module->adminPermission ?
125
- \Yii::$app->user->can($this->module->adminPermission) : false)
+ \Yii::$app->authManager->checkAccess($this->id, $this->module->adminPermission) : false)
126
|| in_array($this->username, $this->module->admins);
127
}
128
0 commit comments