Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/whip.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,14 @@ class JanusWhipServer extends EventEmitter {
throw new Error('Invalid configuration, unsupported "debug" level');
this.config = {
janus: {
address: janus.address
address: janus.address,
apisecret: janus.apisecret
},
rest: {
port: rest.port,
basePath: rest.basePath,
app: rest.app
app: rest.app,
https: rest.https
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure what this is supposed to do? But if you're adding properties to the constructor that were not there before, they should be validated first, especially if they're expected to be of a specific type. See what we do for existing properties in the lines above.

},
allowTrickle: (allowTrickle === true),
strictETags: (strictETags === true),
Expand Down Expand Up @@ -166,6 +168,7 @@ class JanusWhipServer extends EventEmitter {
is_admin: false,
address: {
url: this.config.janus.address,
apisecret: this.config.janus.apisecret
},
retry_time_secs: 3,
max_retries: Number.MAX_VALUE
Expand Down