调整xml 获取逻辑。
This commit is contained in:
4
main.py
4
main.py
@@ -96,7 +96,7 @@ def main(chat_type: int):
|
||||
app_id, error_msg = client.login(app_id=app_id)
|
||||
|
||||
if error_msg:
|
||||
print("登录失败")
|
||||
logger.error("登录失败")
|
||||
return
|
||||
|
||||
resp = client.set_callback(token, callback_url)
|
||||
@@ -106,7 +106,7 @@ def main(chat_type: int):
|
||||
if not config.APP_ID:
|
||||
# 更新配置文件中的APP_ID
|
||||
config.update_config('gewechat', 'app_id', app_id)
|
||||
print(f"已将新的APP_ID: {app_id} 写入配置文件")
|
||||
logger.info(f"已将新的APP_ID: {app_id} 写入配置文件")
|
||||
# 同时更新当前配置对象中的APP_ID
|
||||
config.APP_ID = app_id
|
||||
|
||||
|
||||
Reference in New Issue
Block a user