X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/3244635aa11878135a014cf2c9ec9177f8e9d0ba..8b781bb18b406788e2d62dbef07ba1e00e371c78:/app/views/site/edit.html.erb diff --git a/app/views/site/edit.html.erb b/app/views/site/edit.html.erb index b29c0f200..779abd352 100644 --- a/app/views/site/edit.html.erb +++ b/app/views/site/edit.html.erb @@ -20,7 +20,7 @@ <%= render :partial => 'search' %> <% -session[:token] = @user.tokens.create.token unless session[:token] +session[:token] = @user.tokens.create.token unless session[:token] and UserToken.find_by_token(session[:token]) # Decide on a lat lon to initialise potlatch with. Various ways of doing this if params['lon'] and params['lat'] @@ -88,7 +88,7 @@ zoom='14' if zoom.nil? doSWF(<%= lat || 'null' %>,<%= lon || 'null' %>,<%= zoom %>); function setPosition(lat, lon, zoom) { - doSWF(lat, lon, zoom); + doSWF(lat, lon, zoom || 15); } function resizeContent() {