Skip to content

Commit

Permalink
Merge pull request #40 from 5p4k/remove_endpt_on_connect
Browse files Browse the repository at this point in the history
Remove WebsocketRPCEndpoint.on_connect
  • Loading branch information
orweis authored Jul 29, 2024
2 parents d0f322e + 985d07e commit 0e1ec50
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions fastapi_websocket_rpc/websocket_rpc_endpoint.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,14 +107,6 @@ async def handle_disconnect(self, websocket, channel):
self.manager.disconnect(websocket)
await channel.on_disconnect()

async def on_connect(self, channel, websocket):
"""
Called upon new client connection
"""
# Trigger connect callback if available
if (self._on_connect is not None):
asyncio.create_task(self._on_connect(channel, websocket))

def register_route(self, router, path="/ws"):
"""
Register this endpoint as a default websocket route on the given router
Expand Down

0 comments on commit 0e1ec50

Please sign in to comment.