public static function validateLogin($email, $password) { if ($user = user::find(array('email' => $email))) { if (authentication::verify($password, $user["password"])) { return true; } else { return false; } } else { return false; } }