feat(idaa): use URL g_uuid for Jitsi moderator group check

Instead of checking membership across all groups in novi_idaa_group_guid_li
(site config), pass the single g_uuid from the URL param. Each Novi iframe
page supplies the group relevant to that specific meeting, so checking just
that one group is both more precise and avoids unnecessary Novi API calls.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Scott Idem
2026-03-27 14:27:06 -04:00
parent 045efa71e1
commit f111670f60
2 changed files with 9 additions and 3 deletions

View File

@@ -477,10 +477,15 @@ async function fetch_novi_data() {
}
}
const novi_idaa_group_guid_li =
$ae_loc.site_cfg_json?.novi_idaa_group_guid_li ?? [];
// Use the group UUID from the URL param to check membership in that specific group.
// Each Jitsi iframe page passes the relevant group's UUID — this is more precise than
// checking against a global list of all IDAA moderator groups from site config.
const group_uuid = url_params.g_uuid ?? null;
if (!group_uuid) {
console.warn('Jitsi: No g_uuid in URL — skipping group moderator check.');
}
const moderatorIdSet = await get_novi_group_moderators(
novi_idaa_group_guid_li,
group_uuid ? [group_uuid] : [],
novi_api_root_url,
novi_api_key
);

View File

@@ -4,6 +4,7 @@ export function load({ url }) {
return {
params: {
uuid: url.searchParams.get('uuid'),
g_uuid: url.searchParams.get('g_uuid'),
email: url.searchParams.get('email'),
full_name: url.searchParams.get('full_name'),
moderator: url.searchParams.get('moderator'),