Fix idempotent checking to use only failed value