Merge branch 'master' into glitch-soc/merge-upstream
Conflicts: - README.md discarded upstream changes - app/controllers/api/v1/bookmarks_controller.rb finally merged upstream, some code style fixes and slightly changed pagination code - app/controllers/application_controller.rb changed upstream to always return HTML error pages slight conflict caused by theming code - app/models/bookmark.rb finally merged upstream, no real conflict - spec/controllers/api/v1/bookmarks_controller_spec.rb finally merged upstream, slightly changed pagination code
This commit is contained in:
17
db/migrate/20180831171112_create_bookmarks.rb
Normal file
17
db/migrate/20180831171112_create_bookmarks.rb
Normal file
@@ -0,0 +1,17 @@
|
||||
class CreateBookmarks < ActiveRecord::Migration[5.1]
|
||||
def change
|
||||
create_table :bookmarks do |t|
|
||||
t.references :account, null: false
|
||||
t.references :status, null: false
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
safety_assured do
|
||||
add_foreign_key :bookmarks, :accounts, column: :account_id, on_delete: :cascade
|
||||
add_foreign_key :bookmarks, :statuses, column: :status_id, on_delete: :cascade
|
||||
end
|
||||
|
||||
add_index :bookmarks, [:account_id, :status_id], unique: true
|
||||
end
|
||||
end
|
Reference in New Issue
Block a user