diff --git a/streaming/index.js b/streaming/index.js index 30110427..38d9b28f 100644 --- a/streaming/index.js +++ b/streaming/index.js @@ -660,19 +660,20 @@ const startWorker = (workerId) => { streamFrom(channel, req, streamToWs(req, ws), streamWsEnd(req, ws, subscriptionHeartbeat(channel))); }); break; + case 'group': - const groupId = location.query.group; - - authorizeGroupAccess(groupId, req, authorized => { - if (!authorized) { - ws.close(); - return; - } - - channel = `timeline:group:${groupId}`; - streamFrom(channel, req, streamToWs(req, ws), streamWsEnd(req, ws, subscriptionHeartbeat(channel))); - }); - break; + const groupId = location.query.group; + + authorizeGroupAccess(groupId, req, authorized => { + if (!authorized) { + ws.close(); + return; + } + + channel = `timeline:group:${groupId}`; + streamFrom(channel, req, streamToWs(req, ws), streamWsEnd(req, ws, subscriptionHeartbeat(channel))); + }); + break; default: ws.close(); }