added alerts
added close for alert