Skip to content

Instantly share code, notes, and snippets.

@mcmire
Created October 21, 2010 20:45
Show Gist options
  • Save mcmire/639321 to your computer and use it in GitHub Desktop.
Save mcmire/639321 to your computer and use it in GitHub Desktop.
ActiveSupport DateTime sanity
$ irb
>> require 'date'
=> true
>> {"time" => DateTime.new(2010)} == {"time" => "2010-01-01T00:00:00Z"}
=> false
>> require 'activesupport'
=> true
>> {"time" => DateTime.new(2010)} == {"time" => "2010-01-01T00:00:00Z"}
=> true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment