Fixed the bug that caused pressing cancel when prompted for a rename to rename the file null.