mirror of https://github.com/VERT-sh/VERT.git
fix: empty file name fallback
This commit is contained in:
parent
ed8e12769e
commit
b4a650c3c2
|
@ -239,7 +239,7 @@ class Files {
|
|||
const url = URL.createObjectURL(blob);
|
||||
|
||||
const settings = JSON.parse(localStorage.getItem("settings") ?? "{}");
|
||||
const filenameFormat = settings.filenameFormat ?? "VERT_%name%";
|
||||
const filenameFormat = settings.filenameFormat || "VERT_%name%";
|
||||
|
||||
const format = (name: string) => {
|
||||
const date = new Date().toISOString();
|
||||
|
|
|
@ -91,7 +91,7 @@ export class VertFile {
|
|||
if (!to.startsWith(".")) to = `.${to}`;
|
||||
|
||||
const settings = JSON.parse(localStorage.getItem("settings") ?? "{}");
|
||||
const filenameFormat = settings.filenameFormat ?? "VERT_%name%";
|
||||
const filenameFormat = settings.filenameFormat || "VERT_%name%";
|
||||
|
||||
const format = (name: string) => {
|
||||
const date = new Date().toISOString();
|
||||
|
|
Loading…
Reference in New Issue