* removing helper to resolve remote_ip, and doing it the 'rails' way
This commit is contained in:
parent
2e27773511
commit
b74ab7fda9
|
|
@ -31,7 +31,7 @@ class UsersController < ApplicationController
|
|||
end
|
||||
@signup_postback = load_postback(@invited_user)
|
||||
|
||||
load_location(remote_ip())
|
||||
load_location(request.remote_ip)
|
||||
|
||||
@user = User.new
|
||||
@user.musician = true # default the UI to musician as selected option
|
||||
|
|
|
|||
|
|
@ -18,12 +18,4 @@ module ApplicationHelper
|
|||
Rails.application.config.bugsnag_notify_release_stages.include? Rails.env
|
||||
end
|
||||
|
||||
def remote_ip
|
||||
if Rails.application.config.proxy_use_x_real_ip
|
||||
request.env['X-Real-IP']
|
||||
else
|
||||
request.remote_ip
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
|||
|
|
@ -154,7 +154,5 @@ if defined?(Bundler)
|
|||
|
||||
config.ga_ua = 'UA-44184562-2' # google analytics
|
||||
config.ga_suppress_admin = true
|
||||
|
||||
config.proxy_use_x_real_ip = false
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue