Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sfu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alain Takoudjou
sfu
Commits
8fbd16cc
Commit
8fbd16cc
authored
Aug 19, 2020
by
Juliusz Chroboczek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor tweaks to error handling.
parent
74cab721
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
static/protocol.js
static/protocol.js
+1
-1
static/sfu.js
static/sfu.js
+7
-1
No files found.
static/protocol.js
View file @
8fbd16cc
...
...
@@ -150,7 +150,7 @@ ServerConnection.prototype.close = function() {
* @param {message} m - the message to send.
*/
ServerConnection
.
prototype
.
send
=
function
(
m
)
{
if
(
this
.
socket
.
readyState
!==
this
.
socket
.
OPEN
)
{
if
(
!
this
.
socket
||
this
.
socket
.
readyState
!==
this
.
socket
.
OPEN
)
{
// send on a closed connection doesn't throw
throw
(
new
Error
(
'
Connection is not open
'
));
}
...
...
static/sfu.js
View file @
8fbd16cc
...
...
@@ -385,7 +385,11 @@ function stopUpMedia(c) {
*/
function
delUpMedia
(
c
)
{
stopUpMedia
(
c
);
try
{
delMedia
(
c
.
id
);
}
catch
(
e
)
{
console
.
warn
(
e
);
}
c
.
close
(
true
);
delete
(
serverConnection
.
up
[
c
.
id
]);
setButtonsVisibility
()
...
...
@@ -474,6 +478,8 @@ function setMedia(c, isUp) {
function
delMedia
(
id
)
{
let
mediadiv
=
document
.
getElementById
(
'
peers
'
);
let
peer
=
document
.
getElementById
(
'
peer-
'
+
id
);
if
(
!
peer
)
throw
new
Error
(
'
Removing unknown media
'
);
let
media
=
document
.
getElementById
(
'
media-
'
+
id
);
media
.
srcObject
=
null
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment