fix(licensing): rename variant values to skipper/admiral and store resolved type (#379)

Rename internal variant values from 'personal'/'team' to 'skipper'/'admiral',
aligning code with user-facing tier names. Variant type is now resolved once
at activation/validation and stored in DB via license_variant_type, instead
of string-matching the Lemon Squeezy variant_name on every read. Also captures
variant_id for future lookups. Pre-existing installs auto-migrate on first
getVariant() call.
This commit is contained in:
Anso
2026-04-05 18:45:57 -04:00
committed by GitHub
parent 4163af2ee7
commit 797623e56f
17 changed files with 126 additions and 78 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ import { apiFetch } from '@/lib/api';
export type LicenseTier = 'community' | 'paid';
export type LicenseStatus = 'community' | 'trial' | 'active' | 'expired' | 'disabled';
export type LicenseVariant = 'personal' | 'team' | null;
export type LicenseVariant = 'skipper' | 'admiral' | null;
export interface LicenseInfo {
tier: LicenseTier;