Skip to content

Commit

Permalink
more debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
Szer committed Sep 26, 2023
1 parent eef023d commit 45a116b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/VahterBanBot/Bot.fs
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,13 @@ let onUpdate
(logger: ILogger)
(message: Message) = task {

if message.Chat <> null && message.From <> null then
logger.LogDebug $"Received message from chat {message.Chat.Username} ({message.Chat.Id}) from user {message.From.Username} ({message.From.Id})"

if isNull message || isNull message.From then
logger.LogWarning "Received update without message"


// check if message comes from channel, we should delete it immediately
elif botConfig.ShouldDeleteChannelMessages && isChannelMessage message then

Expand Down

0 comments on commit 45a116b

Please sign in to comment.