Core/Framework/Amvc/App/AbstractApp.php
protected function initPermissions()
    {
        if (isset($this->settings) && $this->settings->exists('permissions') && !self::$init_stages[$this->name]['permissions']) {

            $permissions = [
                'admin'
            ];

            if ($this->settings->exists('config')) {
                $permissions[] = 'config';
            }

            $permissions = array_merge($permissions, $this->settings->get('permissions'));

            $this->permissions = new Permissions();
            $this->permissions->set($permissions);

            // Set flat that permission init is done
            self::$init_stages[$this->name]['perms'] = true;
        }
    }
protected function initPermissions()
    {
        if (isset($this->settings) && $this->settings->exists('permissions') && !self::$init_stages[$this->name]['permissions']) {

            $permissions = [
                'admin'
            ];

            if ($this->settings->exists('config')) {
                $permissions[] = 'config';
            }

            $permissions = array_merge($permissions, $this->settings->get('permissions'));

            $this->permissions = new Permissions();
            $this->permissions->set($permissions);

            // Set flat that permission init is done
            self::$init_stages[$this->name]['perms'] = true;
        }
    }
protected function initPermissions ( ) { if ( isset ( $ this -> settings ) && $ this -> settings -> exists ( 'permissions' ) && ! self :: $ init_stages [ $ this -> name ] [ 'permissions' ] ) { $ permissions = [ 'admin' ] ; if ( $ this -> settings -> exists ( 'config' ) ) { $ permissions [ ] = 'config' ; } $ permissions = array_merge ( $ permissions , $ this -> settings -> get ( 'permissions' ) ) ; $ this -> permissions = new Permissions ( ) ; $ this -> permissions -> set ( $ permissions ) ; // Set flat that permission init is done self :: $ init_stages [ $ this -> name ] [ 'perms' ] = true ; } }
Inits apps permissions by addind default values for admin and for config if confix exists
Inits apps permissions by addind default values for admin and for config if confix exists