diff options
Diffstat (limited to 'db/migrate/20231014140431_add_user_to_blog.rb')
-rw-r--r-- | db/migrate/20231014140431_add_user_to_blog.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/db/migrate/20231014140431_add_user_to_blog.rb b/db/migrate/20231014140431_add_user_to_blog.rb new file mode 100644 index 0000000..74af555 --- /dev/null +++ b/db/migrate/20231014140431_add_user_to_blog.rb | |||
@@ -0,0 +1,5 @@ | |||
1 | class AddUserToBlog < ActiveRecord::Migration[7.0] | ||
2 | def change | ||
3 | add_reference :blogs, :user, foreign_key: true | ||
4 | end | ||
5 | end | ||