summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorJacob Vosmaer <contact@jacobvosmaer.nl>2014-08-19 17:43:17 +0200
committerJacob Vosmaer <contact@jacobvosmaer.nl>2014-08-19 17:43:17 +0200
commitdfc5bf6bf712b7d861cb793f87d1fe3292bde2de (patch)
tree40c3829fb5548db78cc5a7cb93cdedd111dafc9a /db
parente354e548b9259cc5b6924459a3b797b573afbe00 (diff)
downloadgitlab-ce-dfc5bf6bf712b7d861cb793f87d1fe3292bde2de.tar.gz
Use the default color when migrating labels
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20140729152420_migrate_taggable_labels.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/db/migrate/20140729152420_migrate_taggable_labels.rb b/db/migrate/20140729152420_migrate_taggable_labels.rb
index 6724be753c2..f747fd71536 100644
--- a/db/migrate/20140729152420_migrate_taggable_labels.rb
+++ b/db/migrate/20140729152420_migrate_taggable_labels.rb
@@ -16,7 +16,7 @@ class MigrateTaggableLabels < ActiveRecord::Migration
def create_label_from_tagging(tagging)
target = tagging.taggable
label_name = tagging.tag.name.tr('?&,', '')
- label = target.project.labels.find_or_create_by(title: label_name)
+ label = target.project.labels.find_or_create_by(title: label_name, color: Label::DEFAULT_COLOR)
if label.valid? && LabelLink.create(label: label, target: target)
print '.'