Skip to content

Commit

Permalink
📝 Change some annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
wiseCirno committed Sep 24, 2024
1 parent 017aa29 commit 6190426
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions bot/Main.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ async def error_handler(_, context: ContextTypes.DEFAULT_TYPE):
_cf_worker_proxy = _env.get_variable("CF_WORKER_PROXY")
_proxy = _env.get_variable("PROXY")
proxy = proxy_init(_proxy) if _proxy else None
# telegram basic params
# Telegram basic params
_bot_token = _env.get_variable("BOT_TOKEN")
_my_user_id = _env.get_variable("MY_USER_ID")
# chatanywhere api token
# ChatAnywhere api token
_chat_anywhere_key = _env.get_variable("CHAT_ANYWHERE_KEY")
# telegram bot api url
# Telegram bot api url
_base_url = 'https://api.telegram.org/bot'
_base_file_url = 'https://api.telegram.org/file/bot'
base_url = f'{_cf_worker_proxy}/{_base_url}' if _cf_worker_proxy else _base_url
Expand Down Expand Up @@ -84,8 +84,8 @@ async def error_handler(_, context: ContextTypes.DEFAULT_TYPE):
if _my_user_id == -1:
logger.info("[Main]: Master's user id not set, telegraph syncing service will not work.")
else:
# core function: sync telegrph H manga to local storage
telegraph = TelegraphHandler(proxy = proxy, user_id = _my_user_id)
# core function: sync Telegraph manga to local storage
telegraph = TelegraphHandler(proxy = proxy, telegram_user_id = _my_user_id)
telegraph_monitor = ConversationHandler(
entry_points = [CommandHandler(command = "komga", callback = telegraph.komga_start)],
states = {KOMGA: [MessageHandler(filters = filters.TEXT, callback = telegraph.add_task)]},
Expand All @@ -94,7 +94,7 @@ async def error_handler(_, context: ContextTypes.DEFAULT_TYPE):
)
neko_chan.add_handler(telegraph_monitor)

# core function: use chatanywhere api to use chatgpt
# core function: use ChatAnywhere api to use chatgpt
chat_anywhere = ChatAnywhereHandler(
proxy = proxy,
user_id = int(_my_user_id),
Expand Down

0 comments on commit 6190426

Please sign in to comment.