🐛 Fix http proxy error.

🐛 修复 http 代理功能手打出错。
This commit is contained in:
Xtao_dada 2021-06-19 22:56:02 +08:00 committed by GitHub
parent 60cb99158b
commit 919b13a38c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -160,7 +160,7 @@ elif not http_addr == '' and not http_port == '':
import python_socks import python_socks
bot = TelegramClient("pagermaid", api_key, api_hash, auto_reconnect=True, bot = TelegramClient("pagermaid", api_key, api_hash, auto_reconnect=True,
proxy=(python_socks.ProxyType.HTTP, proxy_addr, int(proxy_port))) proxy=(python_socks.ProxyType.HTTP, http_addr, int(http_port)))
except: except:
bot = TelegramClient("pagermaid", api_key, api_hash, auto_reconnect=True) bot = TelegramClient("pagermaid", api_key, api_hash, auto_reconnect=True)
elif not mtp_addr == '' and not mtp_port == '' and not mtp_secret == '': elif not mtp_addr == '' and not mtp_port == '' and not mtp_secret == '':