From 4fe74fd112bdd9be208da3f7d4a4636a89c07ee4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miroslav=20=C5=A0ediv=C3=BD?= Date: Sun, 6 Dec 2020 18:49:20 +0100 Subject: [PATCH] + CanWatch. --- internal/websocket/handler/signal.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/internal/websocket/handler/signal.go b/internal/websocket/handler/signal.go index c6cd9cbd..612281a1 100644 --- a/internal/websocket/handler/signal.go +++ b/internal/websocket/handler/signal.go @@ -7,6 +7,10 @@ import ( ) func (h *MessageHandlerCtx) signalRequest(session types.Session) error { + if !session.CanWatch() { + return nil + } + sdp, lite, ice, err := h.webrtc.CreatePeer(session) if err != nil { return err