Exemplo n.º 1
0
 /**
  * @param $route
  * @param array $properties
  * @return bool|void
  */
 public static function allow($route, array $properties)
 {
     if (!Auth::check()) {
         return true;
     }
     return Redirect::route('home');
 }
Exemplo n.º 2
0
 /**
  * @param $route
  * @param array $properties
  * @return bool|void
  */
 public static function allow($route, array $properties)
 {
     if (\Sectorr\Core\Auth\Auth::check()) {
         return true;
     }
     return Redirect::route('login');
 }
Exemplo n.º 3
0
 /**
  * Helper: Returns logged in user.
  *
  * @param $view
  * @return string
  * @throws \Sectorr\Core\Exceptions\ViewNotFoundException
  */
 function user()
 {
     return Auth::user();
 }