fix a bug on delay_for