mirror of
https://github.com/django/daphne.git
synced 2024-11-21 23:46:33 +03:00
Send WebSocket close code on disconnect
This commit is contained in:
parent
8619c31cf9
commit
2bb68654fc
|
@ -165,6 +165,7 @@ class WebSocketProtocol(WebSocketServerProtocol):
|
|||
if not self.muted:
|
||||
self.channel_layer.send("websocket.disconnect", {
|
||||
"reply_channel": self.reply_channel,
|
||||
"code": code,
|
||||
"path": self.unquote(self.path),
|
||||
"order": self.packets_received + 1,
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue
Block a user