diff --git a/bot.py b/bot.py index 05572878..491be3f1 100644 --- a/bot.py +++ b/bot.py @@ -297,7 +297,10 @@ while True: print("@" + username + ": /roll") cmd = text.split(' ', 1) if len(cmd) >= 2: - m = int(cmd[1]) + try: + m = int(cmd[1]) + except ValueError: + telegram.sendmessage(chr(9888) + " Il numero specificato non รจ un intero.") else: m = 100 n = random.randrange(m) + 1