From 273832c0578b0873619ece11a411c5d69a912347 Mon Sep 17 00:00:00 2001 From: yzhh <2596322644@qq.com> Date: Sun, 12 Sep 2021 00:12:44 +0800 Subject: [PATCH] fixed wiki headers function issue --- modules/wiki/__init__.py | 2 +- modules/wiki/dbutils.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/wiki/__init__.py b/modules/wiki/__init__.py index 914f7493..590a803c 100644 --- a/modules/wiki/__init__.py +++ b/modules/wiki/__init__.py @@ -26,7 +26,7 @@ from .getinfobox import get_infobox_pic recommend_modules='wiki_inline', allowed_none=False) async def wiki_wrapper(msg: MessageSession): - if msg.parsed_msg['set']: + if msg.parsed_msg['set'] and not msg.parsed_msg['headers']: await set_start_wiki(msg) elif msg.parsed_msg['iw']: await interwiki(msg) diff --git a/modules/wiki/dbutils.py b/modules/wiki/dbutils.py index 44a8b93a..02799069 100644 --- a/modules/wiki/dbutils.py +++ b/modules/wiki/dbutils.py @@ -64,6 +64,7 @@ class WikiTargetInfo: def config_headers(self, headers, let_it: [bool, None] = True): try: + headers = json.loads(headers) headers_ = json.loads(self.query.headers) if let_it: for x in headers: