mirror of
https://github.com/BreizhHardware/Jellystat.git
synced 2026-01-18 16:27:20 +01:00
Bump version to 1.1.6
Ensure worker exits when task completes
This commit is contained in:
@@ -42,8 +42,9 @@ async function runBackupTask(triggerType = triggertype.Automatic) {
|
||||
}
|
||||
}
|
||||
|
||||
parentPort.on("message", (message) => {
|
||||
parentPort.on("message", async (message) => {
|
||||
if (message.command === "start") {
|
||||
runBackupTask(message.triggertype);
|
||||
await runBackupTask(message.triggertype);
|
||||
process.exit(0); // Exit the worker after the task is done
|
||||
}
|
||||
});
|
||||
|
||||
@@ -28,8 +28,9 @@ async function runFullSyncTask(triggerType = triggertype.Automatic) {
|
||||
}
|
||||
}
|
||||
|
||||
parentPort.on("message", (message) => {
|
||||
parentPort.on("message", async (message) => {
|
||||
if (message.command === "start") {
|
||||
runFullSyncTask(message.triggertype);
|
||||
await runFullSyncTask(message.triggertype);
|
||||
process.exit(0); // Exit the worker after the task is done
|
||||
}
|
||||
});
|
||||
|
||||
@@ -27,8 +27,9 @@ async function runPlaybackReportingPluginSyncTask() {
|
||||
}
|
||||
}
|
||||
|
||||
parentPort.on("message", (message) => {
|
||||
parentPort.on("message", async (message) => {
|
||||
if (message.command === "start") {
|
||||
runPlaybackReportingPluginSyncTask();
|
||||
await runPlaybackReportingPluginSyncTask();
|
||||
process.exit(0); // Exit the worker after the task is done
|
||||
}
|
||||
});
|
||||
|
||||
@@ -28,8 +28,9 @@ async function runPartialSyncTask(triggerType = triggertype.Automatic) {
|
||||
}
|
||||
}
|
||||
|
||||
parentPort.on("message", (message) => {
|
||||
parentPort.on("message", async (message) => {
|
||||
if (message.command === "start") {
|
||||
runPartialSyncTask(message.triggertype);
|
||||
await runPartialSyncTask(message.triggertype);
|
||||
process.exit(0); // Exit the worker after the task is done
|
||||
}
|
||||
});
|
||||
|
||||
2
package-lock.json
generated
2
package-lock.json
generated
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "jfstat",
|
||||
"version": "1.1.5",
|
||||
"version": "1.1.6",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "jfstat",
|
||||
"version": "1.1.5",
|
||||
"version": "1.1.6",
|
||||
"private": true,
|
||||
"main": "src/index.jsx",
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user