fix eternal spinning wheel by calling enable_ui before showing an alert with the error message.