From f218ec32faa697bbe753133b926b612350e8cc44 Mon Sep 17 00:00:00 2001 From: thePR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> Date: Sat, 20 Jun 2026 08:27:41 -0400 Subject: [PATCH] fix(upload): publish uploaded thumbnail URL (was published empty) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Selecting a thumbnail FILE clears+disables the thumbnail text input, but the publish metadata read only that (now-empty) input — so file-uploaded thumbnails published as "thumbnail":"" and the image was missing. Prefer the uploaded thumbnail's URL (thumbnailUploadState.url), falling back to a pasted URL. Co-Authored-By: Claude Opus 4.8 --- js/ui/components/UploadModal.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/js/ui/components/UploadModal.js b/js/ui/components/UploadModal.js index ddd0399e..f3817e7d 100644 --- a/js/ui/components/UploadModal.js +++ b/js/ui/components/UploadModal.js @@ -1042,7 +1042,14 @@ export class UploadModal { const metadata = { title: this.inputs.title?.value?.trim() || "", description: this.inputs.description?.value?.trim() || "", - thumbnail: this.inputs.thumbnail?.value?.trim() || "", + // Prefer an uploaded thumbnail's URL: selecting a thumbnail file + // clears+disables the text input (see the file-picker handler), so + // inputs.thumbnail.value is empty for file uploads. Fall back to a + // pasted URL when no file was uploaded. + thumbnail: + this.thumbnailUploadState?.url || + this.inputs.thumbnail?.value?.trim() || + "", enableComments: this.toggles.comments?.checked || true, ...audienceFlags,