diff options
author | James Lopez <james@jameslopez.es> | 2017-04-05 16:59:28 +0200 |
---|---|---|
committer | James Lopez <james@jameslopez.es> | 2017-04-05 16:59:28 +0200 |
commit | 44ec40028c60b4f3a5d3f1bb049996f4d2caf9af (patch) | |
tree | 1ebbc45dba010aac1ac022368843078fd34f2ecd /db | |
parent | 0bd4c17ee6480e88e05bb1a614c0d88819a37c74 (diff) | |
download | gitlab-ce-44ec40028c60b4f3a5d3f1bb049996f4d2caf9af.tar.gz |
fix project authorizations migration issue
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20170130204620_add_index_to_project_authorizations.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/db/migrate/20170130204620_add_index_to_project_authorizations.rb b/db/migrate/20170130204620_add_index_to_project_authorizations.rb index 629b49436e3..8c593c39440 100644 --- a/db/migrate/20170130204620_add_index_to_project_authorizations.rb +++ b/db/migrate/20170130204620_add_index_to_project_authorizations.rb @@ -6,7 +6,9 @@ class AddIndexToProjectAuthorizations < ActiveRecord::Migration disable_ddl_transaction! def up - add_concurrent_index(:project_authorizations, :project_id) + unless index_exists?(:project_authorizations, :project_id) + add_concurrent_index(:project_authorizations, :project_id) + end end def down |