summaryrefslogtreecommitdiffstats
path: root/sonar-server/src
diff options
context:
space:
mode:
authorFabrice Bellingard <fabrice.bellingard@sonarsource.com>2012-10-08 11:29:38 +0200
committerFabrice Bellingard <fabrice.bellingard@sonarsource.com>2012-10-08 16:14:52 +0200
commit422de7b07eb1b281a27b7085e6fb49a36cf2eace (patch)
tree765d235e9d77c2c10ded1b52f0b20fd719f6143d /sonar-server/src
parent57c3ca338db31771c1bb605eee12a7017de46ab7 (diff)
downloadsonarqube-422de7b07eb1b281a27b7085e6fb49a36cf2eace.tar.gz
sonarqube-422de7b07eb1b281a27b7085e6fb49a36cf2eace.zip
Fix regression when saving widget configuration
=> params[:resource_id] can be null in case of non global dashboard
Diffstat (limited to 'sonar-server/src')
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/controllers/dashboard_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/dashboard_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/dashboard_controller.rb
index a4d9cce2c80..08f0b5a9291 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/dashboard_controller.rb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/dashboard_controller.rb
@@ -119,7 +119,7 @@ class DashboardController < ApplicationController
prop.save!
end
end
- widget.resource_id=Project.by_key(params[:resource_id]).id
+ widget.resource_id=Project.by_key(params[:resource_id]).id if params[:resource_id]
widget.configured=true
widget.save!
render :update do |page|