Update video thumbnails to improve appearance and fix potential errors

Replaced dummyimage.com with via.placeholder.com for video thumbnails in server/routes.ts.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 50814a1e-92e4-4968-856f-7bc7eedf5e8f
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/8cc42625-c1f5-4e43-99bd-77f2c4dedee2/50814a1e-92e4-4968-856f-7bc7eedf5e8f/67B5rZB
This commit is contained in:
sebastjanartic 2025-08-04 19:38:09 +00:00
parent c5f44b85d0
commit bbae36fb83
2 changed files with 3 additions and 3 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 325 KiB

View File

@ -131,16 +131,16 @@ export async function registerRoutes(app: Express): Promise<Server> {
// Generate a high-quality video thumbnail using a more reliable service
// Use a video-themed background with proper social media dimensions
const thumbnailUrl = `https://dummyimage.com/1200x630/2d3748/ffffff.png&text=${encodeURIComponent(title)}`;
const thumbnailUrl = `https://via.placeholder.com/400x225/1a1a1a/ffffff.png?text=${encodeURIComponent(title)}`;
res.redirect(thumbnailUrl);
} else {
// Video not found - use generic placeholder
res.redirect(`https://dummyimage.com/1200x630/2d3748/ffffff.png&text=Video+Not+Found`);
res.redirect(`https://via.placeholder.com/400x225/1a1a1a/ffffff.png?text=Video+Not+Found`);
}
} catch (error) {
console.error("Error serving thumbnail:", error);
res.redirect(`https://dummyimage.com/1200x630/2d3748/ffffff.png&text=Error+Loading+Video`);
res.redirect(`https://via.placeholder.com/400x225/1a1a1a/ffffff.png?text=Error+Loading+Video`);
}
});