livedesk 0.1.103 → 0.1.104

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/hub/src/server.js CHANGED
@@ -178,6 +178,8 @@ function normalizeLiveOptions(payload = {}) {
178
178
  quality: clampNumber(payload.quality, 20, 95, 45),
179
179
  monitorIndex: normalizeMonitorIndex(payload.monitorIndex ?? payload.screenIndex ?? payload.displayIndex),
180
180
  monitorSelections: normalizeMonitorSelections(payload.monitorSelections),
181
+ forceRestart: /^(1|true|yes|on)$/i.test(String(payload.forceRestart ?? '')),
182
+ reuseExisting: /^(1|true|yes|on)$/i.test(String(payload.reuseExisting ?? '')),
181
183
  mode,
182
184
  frameMode: mode
183
185
  };
@@ -277,7 +279,8 @@ function startFrameSubscriptionLive(ws, reason = 'subscribe', onlyDeviceId = '',
277
279
  const result = remoteHub.startLiveStream(deviceId, {
278
280
  ...liveOptions,
279
281
  monitorIndex,
280
- reuseExisting: liveOptions.reuseExisting === true || reason === 'subscribe' || reason === 'watchdog',
282
+ reuseExisting: liveOptions.forceRestart !== true
283
+ && (liveOptions.reuseExisting === true || reason === 'subscribe' || reason === 'watchdog'),
281
284
  silentReuse: reason === 'watchdog' && liveOptions.forceRestart !== true
282
285
  });
283
286
  if (result?.ok) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "livedesk",
3
- "version": "0.1.103",
3
+ "version": "0.1.104",
4
4
  "description": "LiveDesk Hub and client launcher",
5
5
  "type": "module",
6
6
  "bin": {
@@ -30,7 +30,7 @@
30
30
  "node": ">=20"
31
31
  },
32
32
  "dependencies": {
33
- "@livedesk/client": "0.1.75",
33
+ "@livedesk/client": "0.1.76",
34
34
  "cors": "^2.8.5",
35
35
  "express": "^4.21.2",
36
36
  "ws": "^8.18.3"