Modify retry method