Fixed a bug where the program would serialize null if the user cancelled out of a file dialog.