mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-13 15:58:50 +00:00
Change how migrations duplicated between glitch and upstream are handled (#2878)
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
# This migration is a duplicate of 20180831171112 and may get ignored, see
|
||||
# config/initializers/0_duplicate_migrations.rb
|
||||
# This migration is a duplicate of 20180831171112
|
||||
|
||||
class GlitchCreateBookmarks < ActiveRecord::Migration[5.1]
|
||||
def up
|
||||
return if table_exists?(:bookmarks)
|
||||
|
||||
class CreateBookmarks < ActiveRecord::Migration[5.1]
|
||||
def change
|
||||
create_table :bookmarks do |t|
|
||||
t.references :account, null: false
|
||||
t.references :status, null: false
|
||||
@@ -19,4 +20,6 @@ class CreateBookmarks < ActiveRecord::Migration[5.1]
|
||||
|
||||
add_index :bookmarks, [:account_id, :status_id], unique: true
|
||||
end
|
||||
|
||||
def down; end
|
||||
end
|
||||
@@ -1,10 +1,11 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
# This migration is a duplicate of 20180410220657 and may get ignored, see
|
||||
# config/initializers/0_duplicate_migrations.rb
|
||||
# This migration is a duplicate of 20180410220657
|
||||
|
||||
class CreateBookmarks < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
def up
|
||||
return if table_exists?(:bookmarks)
|
||||
|
||||
create_table :bookmarks do |t|
|
||||
t.references :account, null: false
|
||||
t.references :status, null: false
|
||||
@@ -19,4 +20,8 @@ class CreateBookmarks < ActiveRecord::Migration[5.2]
|
||||
|
||||
add_index :bookmarks, [:account_id, :status_id], unique: true
|
||||
end
|
||||
|
||||
def down
|
||||
drop_table :bookmarks
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user