Skip to content

Commit 8924384

Browse files
walterbenderWalter Bender
andauthored
fix: ensure save filename is not empty string (#7800)
Co-authored-by: Walter Bender <walter@sorceo.com>
1 parent e58db21 commit 8924384

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

js/SaveInterface.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,10 +232,13 @@ class SaveInterface {
232232
}
233233
this.showToast(message);
234234
};
235+
235236
if (defaultfilename === undefined || defaultfilename === null) {
236237
const planet = this.getPlanetInterface();
237238
defaultfilename =
238-
planet && typeof planet.getCurrentProjectName === "function"
239+
planet &&
240+
typeof planet.getCurrentProjectName === "function" &&
241+
planet.getCurrentProjectName().length > 0
239242
? planet.getCurrentProjectName()
240243
: STR_MY_PROJECT;
241244

0 commit comments

Comments
 (0)