don't do buttbot without password file
This commit is contained in:
parent
bc46ef50e6
commit
d9d0c3eca3
|
@ -20,3 +20,9 @@ def iambuttbot(bot, input):
|
|||
data = urllib.urlencode({"status": status.encode('utf8')})
|
||||
url = 'http://iambuttbot:%s@twitter.com/statuses/update.xml' % password
|
||||
response = urllib.urlopen(url, data)
|
||||
|
||||
try:
|
||||
open('iambuttbot_password')
|
||||
except IOError:
|
||||
print 'iambuttbot twitter password not found: module disabled'
|
||||
del iambuttbot
|
||||
|
|
Loading…
Reference in New Issue