Fixed a bug involving the error dialog.