Fix on type hints

This commit is contained in:
NIC619
2019-07-28 14:30:15 +08:00
parent edd164c878
commit d716e90e17
11 changed files with 34 additions and 28 deletions

View File

@ -25,9 +25,8 @@ class IPubsubRouter(ABC):
:param pubsub: pubsub instance to attach to
"""
# FIXME: Should be changed to type 'peer.ID'
@abstractmethod
def add_peer(self, peer_id: str, protocol_id: str) -> None:
def add_peer(self, peer_id: ID, protocol_id: str) -> None:
"""
Notifies the router that a new peer has been connected
:param peer_id: id of peer to add