Tour the Atmosphere. Switch clients, share universal links, browse any PDS.

fix(og): handle webp avatars from bsky cdn in image routes master

The @vercel/og base64 data-URI decoder only supports png/apng/jpeg/gif/svg. cdn.bsky.app now serves avatars and thumbnails as image/webp, which made the decoder fall through its switch without setting a size, and then throw "TypeError: l is not iterable" when spreading undefined. Introduce a shared fetchImageAsDataUrl helper that: - rewrites cdn.bsky.app URLs with an @jpeg suffix so we always get jpeg - skips (with a warning) any response with an unsupported content-type instead of letting it crash the whole OG render - keeps the existing 3s timeout behavior Used by the post, profile, and list OG routes. Co-authored-by: dame <dame-is@users.noreply.github.com>


+88 -117
4 changed files