]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/user_controller.rb
Some styling changes. Changed drop-down into radio buttons. Tried, and failed, to...
[rails.git] / app / controllers / user_controller.rb
index 2e25719524e0c46c5d0da968831981367ee955f3..603fb2a49aef8a61b0054b907e3bb4f3cd1d1ca5 100644 (file)
@@ -22,8 +22,8 @@ class UserController < ApplicationController
     @title = t 'user.new.title'
     @user = User.new(params[:user])
 
-    country_code = params[:legale] || OSM.IPToCountry(request.remote_ip)
-    @text = OSM.legal_text_for_country(country_code)
+    @legale = params[:legale] || OSM.IPToCountry(request.remote_ip) || APP_CONFIG['default_legale']
+    @text = OSM.legal_text_for_country(@legale)
 
     if @user.invalid?
       render :action => 'new'