Fixed bug where cancelling on save-as crashed the application.