mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2025-12-29 20:14:51 +00:00
Update tcp.py
This commit is contained in:
parent
ab45707f0f
commit
8b87c6ace3
1 changed files with 2 additions and 9 deletions
|
|
@ -20,11 +20,7 @@ import asyncio
|
|||
import ipaddress
|
||||
import logging
|
||||
import socket
|
||||
|
||||
try:
|
||||
import socks
|
||||
except ImportError:
|
||||
socks = None
|
||||
import socks
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
|
@ -43,10 +39,7 @@ class TCP:
|
|||
|
||||
self.loop = asyncio.get_event_loop()
|
||||
|
||||
if proxy and not socks:
|
||||
log.warning("Can't use proxy because pysocks is not installed")
|
||||
|
||||
if proxy and socks:
|
||||
if proxy:
|
||||
hostname = proxy.get("hostname")
|
||||
|
||||
try:
|
||||
|
|
|
|||
Loading…
Reference in a new issue