changed popup error to alert