Added cast to mongo ObjectID.