[Calc] Why didn't I notice this?
parent
2b2001905d
commit
66fc3f6a78
2
calc.py
2
calc.py
|
@ -43,7 +43,7 @@ def c(phenny, input):
|
||||||
return phenny.reply("Nothing to calculate.")
|
return phenny.reply("Nothing to calculate.")
|
||||||
q = input.group(2).encode('ascii', 'ignore')
|
q = input.group(2).encode('ascii', 'ignore')
|
||||||
if '__' in q:
|
if '__' in q:
|
||||||
phenny.reply("Sorry, but no double underscores.")
|
return phenny.reply("Sorry, but no double underscores.")
|
||||||
print("[LOG]: %s calculated '%s'" % (input.nick, q))
|
print("[LOG]: %s calculated '%s'" % (input.nick, q))
|
||||||
try:
|
try:
|
||||||
phenny.say(repr(eval(q, {'__builtins__': env}, {})))
|
phenny.say(repr(eval(q, {'__builtins__': env}, {})))
|
||||||
|
|
Loading…
Reference in New Issue