This commit is contained in:
Daniil Gentili 2017-03-25 03:22:07 +01:00
parent 524cede469
commit fcf577b374
2 changed files with 2 additions and 2 deletions

View File

@ -56,7 +56,7 @@ trait MsgIdHandler
}
} else {
if ($new_message_id->compare($key) <= 0) {
\danog\MadelineProto\Logger::log(['WARNING: Given message id ('.$new_message_id.') is lower than or equal than the current limit ('.$message_id.').'], \danog\MadelineProto\Logger::WARNING);
\danog\MadelineProto\Logger::log(['WARNING: Given message id ('.$new_message_id.') is lower than or equal than the current limit ('.$key.').'], \danog\MadelineProto\Logger::WARNING);
}
}

View File

@ -323,7 +323,7 @@ trait ResponseHandler
{
switch ($server_answer['error_code']) {
case 303:
$this->datacenter->curdc = $datacenter = preg_replace('/[^0-9]+/', '', $server_answer['error_message']);
$this->datacenter->curdc = $datacenter = (int)preg_replace('/[^0-9]+/', '', $server_answer['error_message']);
throw new \danog\MadelineProto\Exception('Received request to switch to DC '.$this->datacenter->curdc);
case 401:
switch ($server_answer['error_message']) {