Explorar o código

fix 0f83a816: set last modified date when not specified

tophf %!s(int64=2) %!d(string=hai) anos
pai
achega
f75e201564
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/background/utils/db.js

+ 1 - 1
src/background/utils/db.js

@@ -596,7 +596,7 @@ export async function parseScript(src) {
     }
     delete script[INFERRED];
   }
-  props.lastModified = props.lastUpdated = src.lastModified;
+  props.lastModified = props.lastUpdated = src.lastModified || Date.now();
   props.uuid = props.uuid || getUUID();
   // Overwriting inner data by `src`, deleting keys for which `src` specifies `null`
   for (const key of ['config', 'custom', 'props']) {