mirror of
https://github.com/appinfosapienza/so-un-bot.git
synced 2025-03-13 16:05:22 +01:00
Move SendToEveryone on its own Thread
This commit is contained in:
parent
53857456ed
commit
07daa07cf2
1 changed files with 5 additions and 1 deletions
|
@ -107,7 +107,11 @@ namespace SoUnBot.Telegram
|
||||||
chatId: chatId,
|
chatId: chatId,
|
||||||
text: "Invio annuncio in corso...",
|
text: "Invio annuncio in corso...",
|
||||||
cancellationToken: cancellationToken);
|
cancellationToken: cancellationToken);
|
||||||
SendToEveryone(botClient, chatId, update.Message.Text.Substring(6));
|
new Thread(() =>
|
||||||
|
{
|
||||||
|
Thread.CurrentThread.IsBackground = true;
|
||||||
|
SendToEveryone(botClient, chatId, update.Message.Text.Substring(6));
|
||||||
|
}).Start();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue