Trasform ObjectIdHex to ObjectId on update if needed