BigW Consortium Gitlab

Commit 83cd3d79 by Rémy Coutable

Merge branch 'zj-gitorious-migration-empty-pg-database' into 'master'

Support empty PG database too cc @rdavila @axil See merge request !6221
parents e9e8c67f 083c0e28
......@@ -8,12 +8,11 @@ class DropGitoriousFieldFromApplicationSettings < ActiveRecord::Migration
require 'yaml'
import_sources = connection.execute('SELECT import_sources FROM application_settings;')
return unless import_sources.first # support empty databases
yaml = if Gitlab::Database.postgresql?
import_sources.values[0][0]
else
return unless import_sources.first
import_sources.first[0]
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment