Fix retry bug