diff options
author | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-08-19 19:42:55 +0400 |
---|---|---|
committer | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-08-19 19:42:55 +0400 |
commit | e354e548b9259cc5b6924459a3b797b573afbe00 (patch) | |
tree | 869cd6513e567f7315663e5b8d556c76ac54d200 /db | |
parent | 7e0a2b3b3dac62541abf990ca633cb272c58d4cf (diff) |
Remove invalid characters from the label name
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20140729152420_migrate_taggable_labels.rb | 2 |
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 06b60a1c92f..6724be753c2 100644 --- a/db/migrate/20140729152420_migrate_taggable_labels.rb +++ b/db/migrate/20140729152420_migrate_taggable_labels.rb @@ -15,7 +15,7 @@ class MigrateTaggableLabels < ActiveRecord::Migration def create_label_from_tagging(tagging) target = tagging.taggable - label_name = tagging.tag.name + label_name = tagging.tag.name.tr('?&,', '') label = target.project.labels.find_or_create_by(title: label_name) if label.valid? && LabelLink.create(label: label, target: target) |