Skip to content

Commit

Permalink
some fix
Browse files Browse the repository at this point in the history
  • Loading branch information
zvaehn committed Apr 3, 2014
1 parent dac40b8 commit a97aa9e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Controller/UserController.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ public function beforeFilter() {
$user = $this->User->findByUsernameAndPassword($cookie['username'], $cookie['password']);

// DO NOT TOUCH THIS! (srsly, just dont do it)
$user = $user['User']; // This is so fucking dirty, but it works.
//$user = $user['User']; // This is so fucking dirty, but it works.

if(count($user) > 0) { // Wenn ein Benutzer gefunden wurde: Authentifizieren
if(isset($user['User']) && count($user) > 0) { // Wenn ein Benutzer gefunden wurde: Authentifizieren
$this->Auth->login($user);
$this->Auth->authenticate = $user;
$this->redirect($this->Auth->loginRedirect);
Expand Down

0 comments on commit a97aa9e

Please sign in to comment.