@7365admin1/core 3.65.0 → 3.65.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -11042,6 +11042,13 @@ function effectiveSiteModules(orgModules, siteModules) {
11042
11042
  const allowed = site.filter((key) => org.includes(key));
11043
11043
  return allowed.length ? allowed : org;
11044
11044
  }
11045
+ function siteModulesForOrg(site, orgId) {
11046
+ const org = orgId?.toString() ?? "";
11047
+ if (!org)
11048
+ return site?.metadata?.modules;
11049
+ const owner = String(site?.orgId ?? site?.org ?? "");
11050
+ return owner && owner === org ? site?.metadata?.modules : void 0;
11051
+ }
11045
11052
  function rejectedSiteModules(orgModules, requested) {
11046
11053
  if (!narrows(orgModules))
11047
11054
  return [];
@@ -20424,7 +20431,7 @@ async function moduleCeiling(org, site) {
20424
20431
  ]);
20425
20432
  return effectiveSiteModules(
20426
20433
  orgDoc?.modules,
20427
- siteDoc?.metadata?.modules
20434
+ siteModulesForOrg(siteDoc, orgId)
20428
20435
  );
20429
20436
  } catch {
20430
20437
  return [];