snapshot of https://github.com/jitsi/jitsi-meet.git @ fd1749dd28f4138aa80234fc7f311b19aaffa0e7 (2026-09-15)
This commit is contained in:
27
react/features/old-client-notification/functions.ts
Normal file
27
react/features/old-client-notification/functions.ts
Normal file
@@ -0,0 +1,27 @@
|
||||
import { browser } from '../base/lib-jitsi-meet';
|
||||
|
||||
/**
|
||||
* Returns true if Jitsi Meet is running in too old jitsi-meet-electron app and false otherwise.
|
||||
*
|
||||
* @returns {boolean} - True if Jitsi Meet is running in too old jitsi-meet-electron app and false otherwise.
|
||||
*/
|
||||
export function isOldJitsiMeetElectronApp() {
|
||||
if (!browser.isElectron()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// @ts-ignore
|
||||
const match = navigator.userAgent.match(/(JitsiMeet)\s*\/\s*((\d+)\.[^\s]*)/);
|
||||
|
||||
if (!Array.isArray(match) || match.length < 3) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const majorVersion = Number(match[3]);
|
||||
|
||||
if (isNaN(majorVersion) || majorVersion >= 2022) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
Reference in New Issue
Block a user