commented the code
alert on closing