mirror of
https://github.com/eliasstepanik/filesystem-livesync.git
synced 2026-01-27 05:18:34 +00:00
commit
7c84a285a9
@ -82,7 +82,10 @@ async function runEngine() {
|
|||||||
log(`Failed! Reason:${result.reason}`);
|
log(`Failed! Reason:${result.reason}`);
|
||||||
} else {
|
} else {
|
||||||
log(`OK: stdout:${result.value.stdout}`);
|
log(`OK: stdout:${result.value.stdout}`);
|
||||||
log(`OK: stderr:${result.value.stderr}`);
|
const stderr = result.value.stderr;
|
||||||
|
if (stderr !== "") {
|
||||||
|
log(`OK: stderr:${stderr}`);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -369,6 +372,7 @@ async function eachProc(syncKey: string, config: eachConf) {
|
|||||||
while (running[syncKey]) {
|
while (running[syncKey]) {
|
||||||
await delay(100);
|
await delay(100);
|
||||||
}
|
}
|
||||||
|
let result = true;
|
||||||
try {
|
try {
|
||||||
running[syncKey] = true;
|
running[syncKey] = true;
|
||||||
if (isKnownFile(syncKey, fromDoc._id, fromDoc._rev)) {
|
if (isKnownFile(syncKey, fromDoc._id, fromDoc._rev)) {
|
||||||
@ -395,11 +399,12 @@ async function eachProc(syncKey: string, config: eachConf) {
|
|||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
log("Exception on transfer doc");
|
log("Exception on transfer doc");
|
||||||
log(ex);
|
log(ex);
|
||||||
|
result = false;
|
||||||
}
|
}
|
||||||
} finally {
|
} finally {
|
||||||
running[syncKey] = false;
|
running[syncKey] = false;
|
||||||
}
|
}
|
||||||
return false;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (config.sync_on_connect || config.server.initialScan) {
|
if (config.sync_on_connect || config.server.initialScan) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user