mirror of
https://github.com/varun-r-mallya/py-libp2p.git
synced 2026-02-09 22:50:54 +00:00
Change async def write
To return `None` instead of `int. `Writer.write` *does* write all data in all use case.
This commit is contained in:
@ -27,8 +27,8 @@ class NoiseConnection(BaseSession):
|
||||
async def read(self, n: int = None) -> bytes:
|
||||
return await self.conn.read(n)
|
||||
|
||||
async def write(self, data: bytes) -> int:
|
||||
return await self.conn.write(data)
|
||||
async def write(self, data: bytes) -> None:
|
||||
await self.conn.write(data)
|
||||
|
||||
async def close(self) -> None:
|
||||
await self.conn.close()
|
||||
|
||||
Reference in New Issue
Block a user