dektrium\rbac\migrations\Migration::findRole PHP Method

findRole() protected method

Finds the role or throws an exception if it is not found.
protected findRole ( string $name ) : Role | null
$name string
return yii\rbac\Role | null
    protected function findRole($name)
    {
        $role = $this->authManager->getRole($name);
        if ($role instanceof Role) {
            return $role;
        }
        return null;
    }