OrgEntitlementsProvider constructor

OrgEntitlementsProvider(
  1. String orgId
)

Per-organization entitlements — what does THIS org's plan unlock, regardless of which orgs the caller also belongs to.

Returns a lightweight wrapper around the org_entitlements() Postgres function. Screens gated by org-scoped features (SSO, webhooks, learning paths, etc.) should watch this provider for the specific orgId they're displaying, NOT currentEntitlements, to avoid a multi-org edge case where a user who belongs to an enterprise org on the side incorrectly sees their trial org as unlocked.

Copied from orgEntitlements.

Implementation

OrgEntitlementsProvider(String orgId)
  : this._internal(
      (ref) => orgEntitlements(ref as OrgEntitlementsRef, orgId),
      from: orgEntitlementsProvider,
      name: r'orgEntitlementsProvider',
      debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
          ? null
          : _$orgEntitlementsHash,
      dependencies: OrgEntitlementsFamily._dependencies,
      allTransitiveDependencies:
          OrgEntitlementsFamily._allTransitiveDependencies,
      orgId: orgId,
    );