RailsCasts Pro episodes are now free!

Learn more or hide this

Peter Tellgren's Profile

GitHub User: petertellgren

Site: tellgren.com

Comments by Peter Tellgren

Avatar

Thanks,
I did look through the source and found that I can pass the unit I want as an options hash allowing me to provider user switching in the future.

ruby
Location.near(params[:search], 50, {:order => :distance, :units => :km})
Avatar

Awesome cast, concise and clear.

been playing with the gem but cannot figure out how to change from miles to km or is this even an option?