From d6273e70cfe58cf483ae3360fa997f86a906794b Mon Sep 17 00:00:00 2001 From: sebastjanartic <45803536-sebastjanartic@users.noreply.replit.com> Date: Fri, 29 Aug 2025 01:00:56 +0000 Subject: [PATCH] Improve how video descriptions are retrieved from Bunny.net Update BunnyService to consistently check metaTags for video descriptions, ensuring that the 'description' property within metaTags is correctly extracted and utilized when available. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 2eb1084e-b728-4449-9231-f1665924c8d5 Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/8cc42625-c1f5-4e43-99bd-77f2c4dedee2/2eb1084e-b728-4449-9231-f1665924c8d5/lLmu7SJ --- server/bunny.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/server/bunny.ts b/server/bunny.ts index e29a277..0f831b2 100644 --- a/server/bunny.ts +++ b/server/bunny.ts @@ -84,13 +84,12 @@ export class BunnyService { // Extract description from BunnyVideoDetails if available let description = 'description' in bunnyVideo ? bunnyVideo.description || "" : ""; - // If no description, check metaTags for description - if (!description && bunnyVideo.metaTags && bunnyVideo.metaTags.length > 0) { + // Always check metaTags for description since Bunny.net stores it there + if (bunnyVideo.metaTags && bunnyVideo.metaTags.length > 0) { const descriptionTag = bunnyVideo.metaTags.find((tag: any) => - tag.property?.toLowerCase().includes('description') || - tag.property?.toLowerCase().includes('summary') + tag.property?.toLowerCase() === 'description' ); - if (descriptionTag) { + if (descriptionTag && descriptionTag.value) { description = descriptionTag.value; } }