WIP: Handling a new pylint design checker message #17
|
@ -7,14 +7,15 @@ from .util import I2PThread
|
|||
|
||||
class I2PDialer(I2PThread):
|
||||
def __init__(
|
||||
self, state, destination, nick, sam_host='127.0.0.1', sam_port=7656
|
||||
self, state, destination, nick=None, *, sam_host=None, sam_port=None
|
||||
):
|
||||
|
||||
self.sam_host = sam_host
|
||||
self.sam_port = sam_port
|
||||
# Initially 127.0.0.1:7656
|
||||
self.sam_host = sam_host or state.i2p_sam_host
|
||||
self.sam_port = sam_port or state.i2p_sam_port
|
||||
|
||||
self.nick = nick
|
||||
self.destination = destination
|
||||
self.nick = nick or state.i2p_session_nick
|
||||
|
||||
super().__init__(state, name='I2P Dial to {}'.format(self.destination))
|
||||
|
||||
|
|
|
@ -156,10 +156,7 @@ class Manager(threading.Thread):
|
|||
if port == 'i2p' and shared.i2p_enabled:
|
||||
if shared.i2p_session_nick and host != shared.i2p_dest_pub:
|
||||
try:
|
||||
d = I2PDialer(
|
||||
shared,
|
||||
host, shared.i2p_session_nick,
|
||||
shared.i2p_sam_host, shared.i2p_sam_port)
|
||||
d = I2PDialer(shared, host)
|
||||
d.start()
|
||||
hosts.add(d.destination)
|
||||
shared.i2p_dialers.add(d)
|
||||
|
|
Loading…
Reference in New Issue
Block a user