error modal dialog - having a bug