Member Junction
    Preparing search index...
    • Check a rendered scope template against its source, for fields that RESTRICT (ExtraFilter, MetadataFilter, ExternalIndexConfig).

      This catches the two ways a restriction can evaporate during rendering, neither of which the value alone can reveal — by the time a provider sees the constraint, the source template has been discarded, so "authored but rendered to nothing" is indistinguishable from "never authored":

      1. Rendered empty. RenderScopeTemplate runs Nunjucks with throwOnUndefined: false, so a mistyped dimension (SecondaryScopes.EffectiveChanneID) makes a {% if %} guard false and the entire restricting clause silently disappears — the lane then runs unrestricted. (We deliberately do NOT flip throwOnUndefined: legitimate templates output optional dimensions, and flipping it would break them all.)
      2. Template leaked through. On a render error RenderScopeTemplate returns the RAW template, so {% if %}/{{ }} syntax reaches a filter as literal text.

      Parameters

      • source: string

        the un-rendered template from the scope row

      • rendered: unknown

        the output of RenderScopeTemplate / RenderScopeJsonTemplate

      Returns ScopeFilterCheck<unknown>