original_string: protected function controlAccessAdmin()
      {
          if ($this->is_backend && !$this->isSuperadmin()) {
  
              if (empty($this->current_user['role_status']) || !$this->access('admin')) {
                  $this->redirect('/', $this->text('No access'), 'warning');
              }
  
              if (isset($this->current_route['access']) && !$this->access($this->current_route['access'])) {
                  $this->setHttpStatus(403);
              }
          }
      }
code: protected function controlAccessAdmin()
      {
          if ($this->is_backend && !$this->isSuperadmin()) {
  
              if (empty($this->current_user['role_status']) || !$this->access('admin')) {
                  $this->redirect('/', $this->text('No access'), 'warning');
              }
  
              if (isset($this->current_route['access']) && !$this->access($this->current_route['access'])) {
                  $this->setHttpStatus(403);
              }
          }
      }
code_tokens: protected function controlAccessAdmin ( ) { if ( $ this -> is_backend && ! $ this -> isSuperadmin ( ) ) { if ( empty ( $ this -> current_user [ 'role_status' ] ) || ! $ this -> access ( 'admin' ) ) { $ this -> redirect ( '/' , $ this -> text ( 'No access' ) , 'warning' ) ; } if ( isset ( $ this -> current_route [ 'access' ] ) && ! $ this -> access ( $ this -> current_route [ 'access' ] ) ) { $ this -> setHttpStatus ( 403 ) ; } } }
docstring: Controls access to admin pages
docstring_tokens: Controls access to admin pages