mirror of
https://github.com/bitinflow/server.git
synced 2026-11-01 05:09:10 +00:00
1 parent
d9fca62c17
commit
78c06f8fc4
1 file changed
+2
-2
@@ -145,13 +145,13 @@ export default function(opt) {
|
||||
server.on('upgrade', (req, socket, head) => {
|
||||
const hostname = req.headers.host;
|
||||
if (!hostname) {
|
||||
sock.destroy();
|
||||
socket.destroy();
|
||||
return;
|
||||
}
|
||||
|
||||
const clientId = GetClientIdFromHostname(hostname);
|
||||
if (!clientId) {
|
||||
sock.destroy();
|
||||
socket.destroy();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user