]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/application_controller.rb
Converted roundabouts to take "1st, 2nd, 3rd" exit etc
[rails.git] / app / controllers / application_controller.rb
index a24df48e08b0dcc8da6b2d54fb7c078ff3da4172..c354b53862c19899373b09f50b6330d22322954d 100644 (file)
@@ -296,13 +296,13 @@ class ApplicationController < ActionController::Base
   end
 
   def preferred_languages
-    @languages ||= if params[:locale]
-                     Locale.list(params[:locale])
-                   elsif current_user
-                     current_user.preferred_languages
-                   else
-                     Locale.list(http_accept_language.user_preferred_languages)
-                   end
+    @preferred_languages ||= if params[:locale]
+                               Locale.list(params[:locale])
+                             elsif current_user
+                               current_user.preferred_languages
+                             else
+                               Locale.list(http_accept_language.user_preferred_languages)
+                             end
   end
 
   helper_method :preferred_languages