Allow optional peer ID in a security session

This commit is contained in:
Alex Stokes 2019-08-16 14:08:27 -07:00
parent 27c0a4f77b
commit 23f53ef954
No known key found for this signature in database
GPG Key ID: 51CE1721B245C086

View File

@ -20,7 +20,10 @@ class BaseSession(ISecureConn):
remote_permanent_pubkey: PublicKey
def __init__(
self, transport: BaseSecureTransport, conn: IRawConnection, peer_id: ID
self,
transport: BaseSecureTransport,
conn: IRawConnection,
peer_id: Optional[ID] = None,
) -> None:
self.local_peer = transport.local_peer
self.local_private_key = transport.local_private_key