Closed pogudin-sergey closed 2 years ago
I am getting this error
if (message.result._ === 'mt_rpc_error') {
TypeError: Cannot read property '_' of undefined
in rpc\index.js:549
I am getting this error
if (message.result._ === 'mt_rpcerror') { TypeError: Cannot read property '' of undefined
in
rpc\index.js:549
How repeat this case?
Thanks! ❤️
Thanks! ❤️
Please, up version for npm
@pogudin-sergey done
@pogudin-sergey done
Thank you!
I am getting this error
if (message.result._ === 'mt_rpcerror') { TypeError: Cannot read property '' of undefined
in
rpc\index.js:549
How repeat this case?
call auth.signIn
method
call
auth.signIn
method
Look params in you call method. Params do not have "_" key. This is not layer problem.
Look params in you call method. Params do not have "_" key. This is not layer problem.
Everything worked fine before updating the layer.
I send these params:
phone_code phone_number phone_code_hash
Don't you have a similar problem?
Don't you have a similar problem?
No problem for 170 users.
Worked code:
sendCode(phone) {
return this.mtproto.call(
'auth.sendCode',
{
phone_number: phone,
api_id: config.telegram.appId,
api_hash: config.telegram.hash,
settings: {
_: 'codeSettings',
current_number: false,
allow_app_hash: false,
},
}
);
}
I guess you miss codeSettings. Please post full code.
I guess you miss codeSettings. Please post full code.
I have no problem with auth.sendCode
method.
//sendCode
this.api.call('auth.sendCode', {
phone_number: this.phone,
settings: {
_: 'codeSettings',
current_number: false,
allow_app_hash: false
},
})
//signIn
this.api.call('auth.signIn', {
phone_code: code,
phone_number: this.phone,
phone_code_hash: codeHash,
}, { syncAuth: true })
I haven't changed my code after updating layer
I guess you do not rebuild new tl shemas. Run scripts in ./node_modules/@mtproto/core directory:
# npm run generate-builder
# npm run generate-parser
I guess you do not rebuild new tl shemas.
Thanks, this is work!!!!!!!!!!! But I just installed new version via npm and I didn't have a scripts folder.
But I just installed new version via npm and I didn't have a scripts folder.
Fix https://github.com/alik0211/mtproto-core/pull/221
Please like )))
Fix UDPATE_APP_TO_LOGIN & up layer to133