import { FSDB_COLLECTION } from 'jsr:@andyburke/fsdb'; import { FSDB_INDEXER_SYMLINKS } from 'jsr:@andyburke/fsdb/indexers'; import { by_lurid } from 'jsr:@andyburke/fsdb/organizers'; export type SESSION = { id: string; user_id: string; secret: string; timestamps: { created: string; expires: string; ended: string; }; }; export const SESSIONS = new FSDB_COLLECTION({ name: 'sessions', indexers: { user_id: new FSDB_INDEXER_SYMLINKS({ name: 'user_id', field: 'user_id', organize: by_lurid }) } });