[backport cloud/1.42] fix: use || instead of ?? and server type in WebcamCapture upload path (#11003)

Backport of #11000 to `cloud/1.42`

Automatically created by backport workflow.

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-11003-backport-cloud-1-42-fix-use-instead-of-and-server-type-in-WebcamCapture-upload--33d6d73d365081ccbb93c1eb16816666)
by [Unito](https://www.unito.io)

Co-authored-by: Christian Byrne <cbyrne@comfy.org>
This commit is contained in:
Comfy Org PR Bot
2026-04-10 08:16:29 +09:00
committed by GitHub
parent 1280a4e37f
commit 1f67eafa40

View File

@@ -143,9 +143,10 @@ app.registerExtension({
throw new Error(err)
}
const data = await resp.json()
const serverName = data.name ?? name
const subfolder = data.subfolder ?? 'webcam'
return `${subfolder}/${serverName} [temp]`
const serverName = data.name || name
const subfolder = data.subfolder || 'webcam'
const type = data.type || 'temp'
return `${subfolder}/${serverName} [${type}]`
}
// @ts-expect-error fixme ts strict error