Skip to content

Instantly share code, notes, and snippets.

@shingara
Created June 14, 2013 12:34
Show Gist options
  • Save shingara/5781477 to your computer and use it in GitHub Desktop.
Save shingara/5781477 to your computer and use it in GitHub Desktop.
Avoid return {'$oid' : 'xxx'} in BSON::ObjectId to_json
module Moped
module BSON
class ObjectId
alias :to_json :to_s
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment