vercel / avatar

💎 Beautiful avatars as a microservice
https://avatar.vercel.sh
MIT License
1.17k stars 71 forks source link

fix: file name parsing #47

Open vaguue opened 1 year ago

vaguue commented 1 year ago

Hello! I have observed an unusual behavior with avatar.vercel.sh. The service only provides users with PNG files, even when .svg is specified at the end of the filename. While attempting to find a potential bug, I discovered another minor issue during my code review: if someone requests https://avatar.vercel.sh/username.svg.png, the service responds with an SVG file, which is not quite accurate. I have corrected this issue.

Best regards, Vaguue.

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
avatar ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 18, 2023 7:16pm
vercel-team commented 1 year ago

📝 Changed routes:

Commit fe2beb4e0035bcda2df60b2d3681ec1a88f65944 (https://avatar-6d1njtsm4.vercel.sh).

styfle commented 1 month ago

This doesn't seem to work. All of these return png

https://avatar-git-fork-vaguue-master.vercel.sh/username.svg https://avatar-git-fork-vaguue-master.vercel.sh/username.png https://avatar-git-fork-vaguue-master.vercel.sh/username.svg.png