From: Fabrice Bellingard Date: Thu, 22 Nov 2012 14:36:31 +0000 (+0100) Subject: SONAR-3919 The "Bulk Deletion" page shouldn't use '%' in the ResourceIndex DB request X-Git-Tag: 3.4~296 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7c455a0afcd122b7adbf5ecc489f359709146745;p=sonarqube.git SONAR-3919 The "Bulk Deletion" page shouldn't use '%' in the ResourceIndex DB request --- diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/bulk_deletion_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/bulk_deletion_controller.rb index a501282f0ef..9cac2bb2a87 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/bulk_deletion_controller.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/bulk_deletion_controller.rb @@ -41,9 +41,9 @@ class BulkDeletionController < ApplicationController # Search for resources conditions = "qualifier=:qualifier" values = {:qualifier => @selected_tab} - if params[:name_filter] + if params[:name_filter] && !params[:name_filter].blank? conditions += " AND kee LIKE :kee" - values[:kee] = '%' + params[:name_filter].strip.downcase + '%' + values[:kee] = params[:name_filter].strip.downcase + '%' end resource_ids = ResourceIndex.find(:all,