Merge pull request #9046 from jitsi/tavram/fix-rec-logo

fix(jaas) fix recorder and sip gateways not detecting vpaas meetings
This commit is contained in:
Avram Tudor 2021-04-22 11:43:17 +03:00 committed by GitHub
commit d8e5b48aeb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 2 deletions

View File

@ -29,11 +29,16 @@ export function extractVpaasTenantFromPath(path: string) {
* @returns {boolean}
*/
export function isVpaasMeeting(state: Object) {
const { billingCounterUrl, iAmRecorder, iAmSipGateway } = state['features/base/config'];
const { jwt } = state['features/base/jwt'];
const isAllowed = iAmRecorder || iAmSipGateway || Boolean(jwt);
return Boolean(
state['features/base/config'].billingCounterUrl
&& state['features/base/jwt'].jwt
billingCounterUrl
&& extractVpaasTenantFromPath(
state['features/base/connection'].locationURL.pathname)
&& isAllowed
);
}