fixed the modal window clearInterval bug