modified for ObjectId spec of MongoDB.