|
|
|
@ -72,6 +72,14 @@ def solveSticker(message):
|
|
|
|
|
print('unknown sticker: ' + fileid)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def solveText(message):
|
|
|
|
|
global replyMsgArray
|
|
|
|
|
text = message['text']
|
|
|
|
|
if '/reload_dictionary_config_file' == text:
|
|
|
|
|
replyMsgArray = json.load(open('dictionary.json'))
|
|
|
|
|
print('dictionary reload.')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def signal_handler(signal, frame):
|
|
|
|
|
print('Keyboard interrupt.')
|
|
|
|
|
os._exit(0)
|
|
|
|
@ -92,6 +100,8 @@ def solveRet(jsonstr):
|
|
|
|
|
message = updateResult['message']
|
|
|
|
|
if 'sticker' in message:
|
|
|
|
|
solveSticker(message)
|
|
|
|
|
if 'text' in message:
|
|
|
|
|
solveText(message)
|
|
|
|
|
return nextid, True
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|