forked from HonusBot/HonusBot
rasoiate
This commit is contained in:
parent
0f4d62f3c0
commit
adb75dcc67
@ -116,13 +116,11 @@ class Config:
|
||||
return self.userAgent
|
||||
|
||||
def jsonasResponse(dct):
|
||||
if "imageUrl" in dct:
|
||||
return JSONResponse(dct["authorized"], dct["success"], dct["imageUrl"], "")
|
||||
elif "htmlDescription" in dct:
|
||||
return JSONResponse(dct["authorized"], dct["success"], "", dct["htmlDescription"])
|
||||
else:
|
||||
if not "imageUrl" in dct or not "htmlDescription" in dct:
|
||||
raise Exception("Invalid JSON")
|
||||
|
||||
return JSONResponse(dct["authorized"], dct["success"], dct["imageUrl"], dct["htmlDescription"])
|
||||
|
||||
class InlineBot:
|
||||
def __init__(self):
|
||||
self.errorText = "Sowwy mawster, an ewror occuwed. ;;w;;"
|
||||
|
Loading…
Reference in New Issue
Block a user