Skip to content
Snippets Groups Projects
Commit 1947aa3d authored by inso's avatar inso
Browse files

Fix behaviour when receiving a block

parent 6e0d16c0
No related branches found
No related tags found
No related merge requests found
...@@ -358,8 +358,7 @@ class Node(QObject): ...@@ -358,8 +358,7 @@ class Node(QObject):
async for msg in ws: async for msg in ws:
if msg.tp == aiohttp.MsgType.text: if msg.tp == aiohttp.MsgType.text:
logging.debug("Received a block : {0}".format(self.pubkey[:5])) logging.debug("Received a block : {0}".format(self.pubkey[:5]))
block_data = block_websocket.parse_text(msg.data) await self.request_current_block()
await self.refresh_block(block_data)
elif msg.tp == aiohttp.MsgType.closed: elif msg.tp == aiohttp.MsgType.closed:
break break
elif msg.tp == aiohttp.MsgType.error: elif msg.tp == aiohttp.MsgType.error:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment