Skip to content

Commit

Permalink
adds not null db constraint on members.member_uid, adds unique index …
Browse files Browse the repository at this point in the history
…on members.member_uid (#713)
  • Loading branch information
nflorentin authored Nov 23, 2023
1 parent b44d559 commit 0ddc6bb
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 50 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
class AddNotNullConstraintToMemberUidInMembers < ActiveRecord::Migration[6.1]
def change
change_column_null :members, :member_uid, false
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
class AddUniqueIndexOnMemberUidInMembers < ActiveRecord::Migration[6.1]
def change
add_index :members, [:organization_id, :member_uid], unique: true
end
end
Loading

0 comments on commit 0ddc6bb

Please sign in to comment.