Refactoring for ExportDialog: Use isOkPressed function