Skip to content

Commit

Permalink
Merge pull request #83 from dadadani/master
Browse files Browse the repository at this point in the history
Check if update actually contains entities
  • Loading branch information
ba0f3 authored Mar 23, 2023
2 parents 9e9bf5c + 4dbfb92 commit 07b0e3e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/telebot/private/utils.nim
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ template hasCommand*(update: Update, username: string): bool =
else:
result = false

if hasMessage and message.entities.isSome:
if hasMessage and message.entities.isSome and message.entities.get.len > 0:
let
entities = message.entities.get()
messageText = message.text.get()
Expand Down

0 comments on commit 07b0e3e

Please sign in to comment.