Fixed crash when no file selected