1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-27 21:44:21 +00:00

Error handling episodio 2

This commit is contained in:
Steffo 2015-10-04 11:40:50 +02:00
parent e175910065
commit e0072abc3f

2
bot.py
View file

@ -15,7 +15,7 @@ while(True):
elif(cmd[0].startswith('/start')): elif(cmd[0].startswith('/start')):
telegram.sendMessage("Ascolta, io mi starto quando mi pare. Anzi, quando @Steffo ha voglia di aprirmi.", sby) telegram.sendMessage("Ascolta, io mi starto quando mi pare. Anzi, quando @Steffo ha voglia di aprirmi.", sby)
elif(cmd[0].startswith('/playing')): elif(cmd[0].startswith('/playing')):
if(cmd[1] is not None): if(len(cmd) >= 1):
n = steam.getNumberOfCurrentPlayers(cmd[1]) n = steam.getNumberOfCurrentPlayers(cmd[1])
if(n == None): if(n == None):
telegram.sendMessage(chr(9888) + " L'app specificata non esiste!", sby) telegram.sendMessage(chr(9888) + " L'app specificata non esiste!", sby)