ManaPHP\Authorization\Rbac::_getPermissionByName PHP Method

_getPermissionByName() protected method

protected _getPermissionByName ( string $name ) : false | Permission
$name string
return false | ManaPHP\Authorization\Rbac\Models\Permission
    protected function _getPermissionByName($name)
    {
        list($module, $controller, $action) = $this->_parsePermissionName($name);
        /**
         * @var \ManaPHP\Authorization\Rbac\Models\Permission $model
         */
        $model = new $this->_permissionModel();
        return $model::findFirst(['module' => $module, 'controller' => $controller, 'action' => $action]);
    }