Added error alert in index