WIP! A BB-style forum, on the ATmosphere! We're still working... we'll be back soon when we have something to show off!
node typescript hono htmx atproto
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

at main 10 lines 476 B view raw
1-- Copy permissions array into the join table before dropping the source column. 2-- ON CONFLICT DO NOTHING makes this idempotent: safe to run on a DB where the 3-- data was already migrated manually (e.g. via scripts/migrate-permissions.ts). 4INSERT INTO "role_permissions" ("role_id", "permission") 5SELECT id, unnest(permissions) 6FROM "roles" 7WHERE permissions IS NOT NULL AND cardinality(permissions) > 0 8ON CONFLICT DO NOTHING; 9 10ALTER TABLE "roles" DROP COLUMN "permissions";