From d83f50e31711f4f5df1ffe7962ccfdd75c45941b Mon Sep 17 00:00:00 2001 From: Enrico Fasoli Date: Sat, 5 Sep 2015 15:51:05 +0200 Subject: [PATCH] implemented error message for PHONE_MIGRATE_X (fix coming soon) --- telecommander.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/telecommander.js b/telecommander.js index 639b935..3ee37c6 100755 --- a/telecommander.js +++ b/telecommander.js @@ -119,7 +119,8 @@ data.onPhoneNumber = function(something,s){ var mindate = moment() data.log('Checking your phone number with Telegram...') data.client.auth.sendCode(data.user.phone,5,'en',function(result){ - if(result.err_code){ + if(result.instanceOf('mtproto.type.Rpc_error')){ + data.switchToBox(data.statusWindow) return data.log('Errors:',result.error_code,result.error_message) } //data.log('Res:',JSON.stringify(result))