mirror of
https://gitlab.com/comunic/comunicapiv2
synced 2024-11-22 05:19:22 +00:00
Can specify a maximum number of users for video calls
This commit is contained in:
parent
62dddb2519
commit
2bb7acc4d7
@ -19,6 +19,7 @@
|
||||
"stun:stun.l.google.com:19302"
|
||||
],
|
||||
"maxUsersPerCalls": 10,
|
||||
"allowVideo": true
|
||||
"allowVideo": true,
|
||||
"maxUsersPerVideoCalls": 4
|
||||
}
|
||||
}
|
@ -28,7 +28,9 @@ export class CallsHelper {
|
||||
* @param conv Target conversation
|
||||
*/
|
||||
public static CanHaveVideoCAll(conv: Conversation) : boolean {
|
||||
return this.CanHaveCall(conv) && conf().rtc_relay.allowVideo;
|
||||
return this.CanHaveCall(conv)
|
||||
&& conf().rtc_relay.allowVideo
|
||||
&& conf().rtc_relay.maxUsersPerVideoCalls >= conv.members.size;
|
||||
}
|
||||
|
||||
}
|
@ -22,6 +22,7 @@ export interface RTCRelayConfiguration {
|
||||
|
||||
maxUsersPerCalls: number,
|
||||
allowVideo: boolean,
|
||||
maxUsersPerVideoCalls: number,
|
||||
}
|
||||
|
||||
export interface Configuration {
|
||||
|
Loading…
Reference in New Issue
Block a user