]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-8416 fix login failure log on logout from the UI
authorSébastien Lesaint <sebastien.lesaint@sonarsource.com>
Wed, 14 Dec 2016 14:52:24 +0000 (15:52 +0100)
committerSébastien Lesaint <sebastien.lesaint@sonarsource.com>
Wed, 14 Dec 2016 16:09:10 +0000 (17:09 +0100)
server/sonar-web/src/main/webapp/WEB-INF/app/controllers/sessions_controller.rb

index 4a302c3457367cd00c581a6b76b578f2605ac547..adc4bf522208c9222fa3b643ecf5117f87df65ba 100644 (file)
@@ -34,7 +34,11 @@ class SessionsController < ApplicationController
     end
     cookies.delete 'JWT-SESSION'
     cookies.delete 'XSRF-TOKEN'
-    redirect_to(home_path)
+    if Api::Utils.java_facade.getConfigurationValue('sonar.forceAuthentication')=='true'
+      redirect_to(home_path + 'sessions/new')
+    else
+      redirect_to(home_path)
+    end
   end
 
   def new