Changing messageloop behaviour and fix missing Device instance in UpdateResult
- simplified for future changes
This commit is contained in:
@@ -22,7 +22,7 @@ namespace DemoBot
|
||||
|
||||
public ExternalActionManager ExternalActionManager { get; set; }
|
||||
|
||||
public async Task MessageLoop(BotBase bot, DeviceSession session, UpdateResult ur, MessageResult mr)
|
||||
public async Task MessageLoop(BotBase bot, DeviceSession s, UpdateResult ur, MessageResult mr)
|
||||
{
|
||||
var update = ur.RawData;
|
||||
|
||||
@@ -34,6 +34,9 @@ namespace DemoBot
|
||||
return;
|
||||
}
|
||||
|
||||
//Remove unecessary parameter from method call in the future
|
||||
var session = ur.Device;
|
||||
|
||||
//Is this a bot command ?
|
||||
if (mr.IsFirstHandler && mr.IsBotCommand && bot.IsKnownBotCommand(mr.BotCommand))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user