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
0067edc6
Commit
0067edc6
authored
Aug 13, 2020
by
Juliusz Chroboczek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix some more Javascript typos.
Thanks to Rémi Nollet and Léo Stefanesco.
parent
fc3ee842
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
9 deletions
+11
-9
static/sfu.js
static/sfu.js
+11
-9
No files found.
static/sfu.js
View file @
0067edc6
...
...
@@ -270,10 +270,10 @@ function newUpStream(id) {
c
.
onerror
=
function
(
e
)
{
console
.
error
(
e
);
displayError
(
e
);
delUpMedia
(
c
.
id
);
delUpMedia
(
c
);
}
c
.
onabort
=
function
()
{
delUpMedia
(
c
.
id
);
delUpMedia
(
c
);
}
return
c
;
}
...
...
@@ -285,14 +285,16 @@ async function addLocalMedia(id) {
let
audio
=
mapMediaOption
(
document
.
getElementById
(
'
audioselect
'
).
value
);
let
video
=
mapMediaOption
(
document
.
getElementById
(
'
videoselect
'
).
value
);
let
old
=
id
&&
serverConnection
.
up
[
id
];
if
(
!
audio
&&
!
video
)
{
if
(
i
d
)
delUpMedia
(
i
d
);
if
(
ol
d
)
delUpMedia
(
ol
d
);
return
;
}
if
(
i
d
)
stopUpMedia
(
i
d
);
if
(
ol
d
)
stopUpMedia
(
ol
d
);
let
constraints
=
{
audio
:
audio
,
video
:
video
};
let
stream
=
null
;
...
...
@@ -300,8 +302,8 @@ async function addLocalMedia(id) {
stream
=
await
navigator
.
mediaDevices
.
getUserMedia
(
constraints
);
}
catch
(
e
)
{
console
.
error
(
e
);
if
(
i
d
)
delUpMedia
(
i
d
);
if
(
ol
d
)
delUpMedia
(
ol
d
);
return
;
}
...
...
@@ -364,7 +366,7 @@ function stopUpMedia(c) {
function
delUpMedia
(
c
)
{
stopUpMedia
(
c
);
delMedia
(
c
);
delMedia
(
c
.
id
);
c
.
close
(
true
);
delete
(
serverConnection
.
up
[
c
.
id
]);
setButtonsVisibility
()
...
...
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