ETRO-438 updates box to only use new refresh keys if save to database succeeds