Merge pull request #37 from laurynas-karvelis/master

Fix edge case when message object is undefined
This commit is contained in:
Mahdi Dibaiee 2018-02-01 19:19:57 +03:30 committed by GitHub
commit 762a6cc309
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,7 +57,7 @@ export default class Base extends EventEmitter {
&& message.reply_to_message.message_id === messageId; && message.reply_to_message.message_id === messageId;
} }
return message.chat.id === chat; return message && message.chat.id === chat;
}); });
if (update) { if (update) {