correctly clearing interval