Skip to content

Commit

Permalink
build: fix migrations with revert for projectrole
Browse files Browse the repository at this point in the history
  • Loading branch information
spwoodcock committed Jan 10, 2024
1 parent 1a4b08b commit aa079a7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion src/backend/migrations/003-project-roles.sql
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ CREATE TYPE public.projectrole as ENUM (
'PROJECT_MANAGER',
'ORGANIZATION_ADMIN'
);
ALTER TYPE public.projectrole OWNER TO fmtm;
ALTER TABLE public.user_roles ALTER COLUMN "role" TYPE public.projectrole;

-- Commit the transaction
Expand Down
2 changes: 1 addition & 1 deletion src/backend/migrations/revert/003-project-roles.sql
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
BEGIN;

-- Revert user_roles table changes
ALTER TABLE public.user_roles ALTER COLUMN "role" TYPE public.userrole;
ALTER TABLE public.user_roles ALTER COLUMN "role" TYPE public.userrole USING role::public.userrole;

-- Drop the public.projectrole enum
DROP TYPE IF EXISTS public.projectrole;
Expand Down

0 comments on commit aa079a7

Please sign in to comment.