File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ const App = () => {
5656 socket . send (
5757 JSON . stringify ( {
5858 event : "candidate" ,
59- data : JSON . stringify ( e . candidate ) ,
59+ data : e . candidate ,
6060 } )
6161 ) ;
6262 }
@@ -71,7 +71,7 @@ const App = () => {
7171 return ;
7272 }
7373
74- const offerCandidate = JSON . parse ( msg . data ) ;
74+ const offerCandidate = msg . data ;
7575
7676 if ( ! offerCandidate ) {
7777 console . log ( "Failed to parse offer msg data" ) ;
@@ -89,7 +89,7 @@ const App = () => {
8989 socket . send (
9090 JSON . stringify ( {
9191 event : "answer" ,
92- data : JSON . stringify ( answer ) ,
92+ data : answer ,
9393 } )
9494 ) ;
9595 } catch ( e ) {
@@ -104,7 +104,7 @@ const App = () => {
104104 case "info" :
105105 dispatch ( {
106106 type : "info" ,
107- viewers : JSON . parse ( msg . data ) . no_connections ,
107+ viewers : msg . data . no_connections ,
108108 } ) ;
109109 }
110110 } ;
You can’t perform that action at this time.
0 commit comments