Skip to content

Commit

Permalink
Make user_id on asciicasts not-nullable
Browse files Browse the repository at this point in the history
  • Loading branch information
ku1ik committed Feb 9, 2025
1 parent 2c31c9b commit 2cfb4b2
Showing 1 changed file with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
defmodule Asciinema.Repo.Migrations.MakeAsciiastUserIdNonNull do
use Ecto.Migration

def change do
alter table(:asciicasts) do
modify :user_id, references(:users), null: false
end

drop constraint(:asciicasts, "asciicasts_user_id_fk")
end
end

0 comments on commit 2cfb4b2

Please sign in to comment.