aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-server/src/main/webapp/WEB-INF
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@gmail.com>2012-10-01 15:05:20 +0200
committerSimon Brandhof <simon.brandhof@gmail.com>2012-10-01 17:32:32 +0200
commit849d1ea4e5e76e98e745765f45bf4730254d64e7 (patch)
treeab97d2f38726531d9d343ae5c9dd240a66a5b22c /sonar-server/src/main/webapp/WEB-INF
parentfc8416951d7a5c9d94cb59371f1e9515cc7e5d81 (diff)
downloadsonarqube-849d1ea4e5e76e98e745765f45bf4730254d64e7.tar.gz
sonarqube-849d1ea4e5e76e98e745765f45bf4730254d64e7.zip
SONAR-3833 Remove dead ruby code
Diffstat (limited to 'sonar-server/src/main/webapp/WEB-INF')
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb22
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_controller.rb6
2 files changed, 9 insertions, 19 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb
index db30cd8f9c3..e633cbc1ffe 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_configuration_controller.rb
@@ -36,19 +36,15 @@ class RulesConfigurationController < ApplicationController
before_filter :admin_required, :except => ['index', 'export']
def index
- unless params[:id].blank?
- if params[:id].to_i<=0
- redirect_to :controller => 'profiles'
- return
- end
- begin
- @profile = Profile.find(params[:id].to_i)
- rescue
- redirect_to :controller => 'profiles'
- return
- end
- else
- @profile = Profile.default_profile
+ if params[:id].to_i<=0
+ redirect_to :controller => 'profiles'
+ return
+ end
+ begin
+ @profile = Profile.find(params[:id].to_i)
+ rescue
+ redirect_to :controller => 'profiles'
+ return
end
init_params()
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_controller.rb
index c3fbea89bed..3d3e6850625 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_controller.rb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/rules_controller.rb
@@ -30,12 +30,6 @@ class RulesController < ApplicationController
@rule=Rule.find(key)
end
@page_title=@rule.name
-
- if params[:resource_id]
- resource = Project.find(params[:resource_id])
- @profile = resource.root_project.profile || Profile.default_profile
- @active_rule = @profile.active_by_rule_id(@rule.id)
- end
end
end