Hello everyone. I have a problem with "request.remote_ip" I made an
array:

1 ip = request.remote_ip
2 $ address [ip] = (: test => "OK")
...
...
...
11 ip = request.remote_ip             # (along with a lot of AJAX calls)
12 response = $ address [ip] [: test]
It often works, but sometimes it gives me this error:

NoMethodError (undefined method `[] 'for nil: NilClass)
app/controllers/my_controller.rb:12...

and refers to the array. All this happens only when I have A LOT OF AJAX
calls simultaneously. But it is possible that request.remote_ip is
"null" during the AJAX calls? Help me please.
-- 
Posted via http://www.ruby-forum.com/.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to