mirror of
https://github.com/pierre42100/ComunicAPI
synced 2025-06-19 00:25:18 +00:00
Fixed error in login process of the API
This commit is contained in:
@ -30,7 +30,7 @@ class userController
|
||||
//Try to perform login
|
||||
$loginTokens = CS::get()->components->user->generateUserLoginTokens($userMail, $userPassword, APIServiceID, $db);
|
||||
|
||||
if(!$loginTokens)
|
||||
if(count($loginTokens) == 0)
|
||||
throw new RestException(401, "Invalid e-mail address / password !");
|
||||
|
||||
//Return result with tokens
|
||||
|
Reference in New Issue
Block a user