diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-21 15:09:07 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-21 15:09:07 +0300 |
commit | 2a040e2655fe0a99df61ad0a7bd0c27e68af0c38 (patch) | |
tree | a245cd0d6dd10f185e2fd098e371adc1ea03b72b /doc/development/migration_style_guide.md | |
parent | a53d2c37c4934f564caa94543dd4cf5af1703e2d (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/development/migration_style_guide.md')
-rw-r--r-- | doc/development/migration_style_guide.md | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/doc/development/migration_style_guide.md b/doc/development/migration_style_guide.md index c15e51c2b9d..1570f9e4096 100644 --- a/doc/development/migration_style_guide.md +++ b/doc/development/migration_style_guide.md @@ -424,16 +424,10 @@ Take the following migration as an example: ```ruby class DefaultRequestAccessGroups < ActiveRecord::Migration[5.2] - include Gitlab::Database::MigrationHelpers - DOWNTIME = false - def up - change_column_default :namespaces, :request_access_enabled, true - end - - def down - change_column_default :namespaces, :request_access_enabled, false + def change + change_column_default(:namespaces, :request_access_enabled, from: false, to: true) end end ``` |