add version check to updates call

This commit is contained in:
2025-11-13 07:05:12 -06:00
parent 81ef5499e0
commit 36357b0daf
+5 -1
View File
@@ -101,7 +101,11 @@ exports.data = function data(_device, oscData) {
} else {
device.data.workspaces[json.workspace_id].permission = 'ok';
device.send(`/workspace/${msgAddr[2]}/cueLists`);
device.send(`/updates`, [{ type: 'i', value: 1 }]);
if (device.data?.version?.startsWith('5')) {
device.send(`/updates`, [{ type: 'i', value: 1 }]);
} else {
device.send(`/workspace/${msgAddr[2]}/updates`, [{ type: 'i', value: 1 }]);
}
}
} else if (/reply\/workspace\/.*\/cueLists/.test(oscData.address)) {
insertChildCues(device, device.data.workspaces[msgAddr[2]].cueLists, json.data, '[root group of cue lists]');