GitHub User: Matt-Bishop
whoops, had those geocoded_by calls reversed
Is it possible to make the method of geocoding conditional? i want to geocode by ip_address by default but if the user updates there current address, I want to then geocode by that.Anyone have ideas on how to do that? something like
class Patron < ActiveRecord::Base
attr_accessible :ip_address, :address, :latitude, :longitude
For anyone who is still using ruby 1.8.7 for rails 3.0.5
SecureRandom.urlsafe_base64 will generate a method not found error. I used SecureRandom.hex as a substitute and it worked. Just thought I'd share in case this helps anyone...