mirror of
https://github.com/danog/MadelineProto.git
synced 2024-11-27 02:34:39 +01:00
Handle AUTH_KEY_PERM_EMPTY errors
This commit is contained in:
parent
715ffb55f5
commit
34cc9bba58
@ -345,6 +345,13 @@ trait ResponseHandler
|
||||
$this->datacenter->sockets[$aargs['datacenter']]->authorized = false;
|
||||
$this->init_authorization(); // idk
|
||||
throw new \danog\MadelineProto\Exception('I had to recreate the temporary authorization key');
|
||||
case 'AUTH_KEY_PERM_EMPTY':
|
||||
if ($this->authorized !== self::LOGGED_IN) {
|
||||
throw new \danog\MadelineProto\RPCErrorException($server_answer['error_message'], $server_answer['error_code']);
|
||||
}
|
||||
$this->datacenter->sockets[$aargs['datacenter']]->temp_auth_key = null;
|
||||
$this->init_authorization(); // idk
|
||||
throw new \danog\MadelineProto\Exception('I had to recreate the temporary authorization key');
|
||||
}
|
||||
case 420:
|
||||
$seconds = preg_replace('/[^0-9]+/', '', $server_answer['error_message']);
|
||||
|
Loading…
Reference in New Issue
Block a user