change to use mongoose for updating result