X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/457ba2e5e8184ff75e15e2ad3ae02c7955e9f15b..f9ae6d252f0126266ff557d003bfa7ea58bf5dff:/app/controllers/user_controller.rb?ds=sidebyside diff --git a/app/controllers/user_controller.rb b/app/controllers/user_controller.rb index 99777ca2d..dbfc44a37 100644 --- a/app/controllers/user_controller.rb +++ b/app/controllers/user_controller.rb @@ -1,5 +1,5 @@ class UserController < ApplicationController - layout :choose_layout + layout 'site', :except => [:api_details] skip_before_filter :verify_authenticity_token, :only => [:api_read, :api_details, :api_gpx_files] before_filter :disable_terms_redirect, :only => [:terms, :save, :logout, :api_details] @@ -786,21 +786,6 @@ private redirect_to :controller => 'user', :action => 'view', :display_name => params[:display_name] unless @this_user end - ## - # Choose the layout to use. See - # https://rails.lighthouseapp.com/projects/8994/tickets/5371-layout-with-onlyexcept-options-makes-other-actions-render-without-layouts - def choose_layout - oauth_url = url_for(:controller => :oauth, :action => :authorize, :only_path => true) - - if [ 'api_details' ].include? action_name - nil - elsif params[:referer] and URI.parse(params[:referer]).path == oauth_url - 'slim' - else - 'site' - end - end - ## # def disable_terms_redirect