From 83d841d1a1c8d871f8477d16d7eb16f1631506d0 Mon Sep 17 00:00:00 2001 From: Simon Brandhof Date: Tue, 11 Dec 2012 10:19:14 +0100 Subject: [PATCH] SONAR-3825 fix migration of conditions on new_ metrics --- .../WEB-INF/db/migrate/360_move_existing_measure_filters.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sonar-server/src/main/webapp/WEB-INF/db/migrate/360_move_existing_measure_filters.rb b/sonar-server/src/main/webapp/WEB-INF/db/migrate/360_move_existing_measure_filters.rb index 9fee2977e5a..606494245f2 100644 --- a/sonar-server/src/main/webapp/WEB-INF/db/migrate/360_move_existing_measure_filters.rb +++ b/sonar-server/src/main/webapp/WEB-INF/db/migrate/360_move_existing_measure_filters.rb @@ -126,7 +126,7 @@ class MoveExistingMeasureFilters < ActiveRecord::Migration data << "c#{metric_criteria_id}_metric=#{old.kee}" data << "c#{metric_criteria_id}_op=#{operator_code(old.operator)}" data << "c#{metric_criteria_id}_val=#{old.value}" - data << "c#{metric_criteria_id}_period=#{old_filter.period_index}" if old.variation && old_filter.period_index + data << "c#{metric_criteria_id}_period=#{old_filter.period_index}" if old_filter.period_index && (old.variation || old.kee.start_with?('new_')) metric_criteria_id += 1 elsif old.family=='direct-children' && old.text_value=='true' data << "onBaseComponents=true" -- 2.39.5