Esempio n. 1
0
 /**
  * This method will be called before we route to the destinated method
  * 
  * @access  public
  * @return  void
  */
 public function before()
 {
     $this->rest = Restserver::is_rest();
     $this->language = Factory::get_language();
     $this->user = Auth::make('user')->get();
     Event::trigger('controller_before');
     if (false === $this->rest) {
         $this->prepare_template();
     } else {
         $this->prepare_rest();
     }
     return parent::before();
 }