added a clearTimeout for previous durations