querysub 0.265.0 → 0.266.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -22,7 +22,7 @@ export function startEdgeNotifier() {
|
|
|
22
22
|
let liveHash = String(deploySchema()[getDomain()].deploy.live.hash);
|
|
23
23
|
if (!Querysub.isAllSynced()) return;
|
|
24
24
|
if (liveHash === lastHashServer) return;
|
|
25
|
-
let refreshThresholdTime = atomicObjectRead(deploySchema()[getDomain()].deploy.live.refreshThresholdTime) || timeInMinute;
|
|
25
|
+
let refreshThresholdTime = atomicObjectRead(deploySchema()[getDomain()].deploy.live.refreshThresholdTime) || (Date.now() + timeInMinute * 15);
|
|
26
26
|
lastHashServer = liveHash;
|
|
27
27
|
if (!curHash) {
|
|
28
28
|
curHash = liveHash;
|
|
@@ -64,6 +64,8 @@ function onLiveHashChange(liveHash: string, refreshThresholdTime: number) {
|
|
|
64
64
|
}
|
|
65
65
|
curHash = liveHash;
|
|
66
66
|
|
|
67
|
+
let duration = refreshThresholdTime - Date.now();
|
|
68
|
+
|
|
67
69
|
// Start notification loop
|
|
68
70
|
void (async () => {
|
|
69
71
|
// Show notifications at intervals
|
|
@@ -71,7 +73,7 @@ function onLiveHashChange(liveHash: string, refreshThresholdTime: number) {
|
|
|
71
73
|
// Don't show if a newer notification is active
|
|
72
74
|
if (curHash !== liveHash) return;
|
|
73
75
|
|
|
74
|
-
let waitDuration = (notifyIntervals[i + 1] - notifyIntervals[i]) *
|
|
76
|
+
let waitDuration = (notifyIntervals[i + 1] - notifyIntervals[i]) * duration;
|
|
75
77
|
// If the duration is short, and it's not the last one, skip it
|
|
76
78
|
if (i < notifyIntervals.length - 2 && waitDuration <= 30 * 1000) continue;
|
|
77
79
|
|
|
@@ -146,6 +146,7 @@ const loadEntryPointsByHash = runInSerial(async function loadEntryPointsByHash(c
|
|
|
146
146
|
FilePath: filePath,
|
|
147
147
|
FunctionId: "entryPoint",
|
|
148
148
|
});
|
|
149
|
+
console.log(magenta(`Loaded entry point from ${gitHash}, path: ${filePath}, resolved to ${module.filename}`));
|
|
149
150
|
|
|
150
151
|
let depth = entryPaths[0].replaceAll("\\", "/").split("/").filter(x => x && x !== ".").length;
|
|
151
152
|
|