From dda4df295ae159d6b726332bf88415424d4f97cb Mon Sep 17 00:00:00 2001 From: Samuel Newman Date: Thu, 26 Jun 2025 11:51:23 +0300 Subject: [PATCH] add logger error --- src/lib/api/index.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/lib/api/index.ts b/src/lib/api/index.ts index 5136e6cc8e..20f0745d69 100644 --- a/src/lib/api/index.ts +++ b/src/lib/api/index.ts @@ -342,6 +342,12 @@ async function resolveMedia( // posting will fail if aspect ratio is set to 0 const aspectRatio = width > 0 && height > 0 ? {width, height} : undefined + if (!aspectRatio) { + logger.error( + `Invalid aspect ratio - got { width: ${videoDraft.asset.width}, height: ${videoDraft.asset.height} }`, + ) + } + return { $type: 'app.bsky.embed.video', video: videoDraft.pendingPublish.blobRef,