diff options
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20170717200542_add_trusted_column_to_oauth_applications.rb | 15 | ||||
-rw-r--r-- | db/schema.rb | 1 |
2 files changed, 16 insertions, 0 deletions
diff --git a/db/migrate/20170717200542_add_trusted_column_to_oauth_applications.rb b/db/migrate/20170717200542_add_trusted_column_to_oauth_applications.rb new file mode 100644 index 00000000000..1a013e6aefb --- /dev/null +++ b/db/migrate/20170717200542_add_trusted_column_to_oauth_applications.rb @@ -0,0 +1,15 @@ +class AddTrustedColumnToOauthApplications < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + disable_ddl_transaction! + + def up + add_column_with_default(:oauth_applications, :trusted, :boolean, default: false) + end + + def down + remove_column(:oauth_applications, :trusted) + end +end diff --git a/db/schema.rb b/db/schema.rb index 63030350c5d..93ab79e14e0 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -1027,6 +1027,7 @@ ActiveRecord::Schema.define(version: 20170725145659) do t.datetime "updated_at" t.integer "owner_id" t.string "owner_type" + t.boolean "trusted", default: false, null: false end add_index "oauth_applications", ["owner_id", "owner_type"], name: "index_oauth_applications_on_owner_id_and_owner_type", using: :btree |