Cleans up mongo interactions