@adonis-agora/media
Version:
Media-library for AdonisJS — owner collections (MIME whitelist, single-file replace, ordering), image conversions (eager/lazy), pluggable content transformers (HLS video via mediabunny, metadata probe, image blur-up placeholder), and column attachments, a
17 lines • 840 B
TypeScript
import type { QueryClientContract } from '@adonisjs/lucid/types/database';
/** What {@link backfillMediaTenants} changes. */
export interface BackfillOptions {
/** Records whose owner is the tenant itself (`Organization`): `tenant_id = owner_id`. */
ownerType: string;
/** The `media` table (default `media`). */
table?: string;
/** Count only, change nothing. */
dryRun?: boolean;
}
/**
* Stamp `tenant_id` on records that have none and whose owner IS the tenant (an `Organization`
* owning its files): `tenant_id = owner_id`. Rows that already have a tenant are left alone.
* Returns how many rows matched (and were updated, unless `dryRun`).
*/
export declare function backfillMediaTenants(client: QueryClientContract, options: BackfillOptions): Promise<number>;
//# sourceMappingURL=tenancy_backfill.d.ts.map