thedevs-network / kutt

Free Modern URL Shortener.
https://kutt.it
MIT License
8.48k stars 1.11k forks source link

Discord Image Preview/Embed Broken #715

Open DananFlander opened 1 year ago

DananFlander commented 1 year ago

Sometime recently Kutt's compatibility with Discord's image embed/preview system began to fail both for kutt.it shortened links as well as for custom domains used through Kutt.

For example, https://i.vgy.me/EfgAMf.png will embed fine and previews the image into the Discord chat, but if you pass that same link through Kutt, changing it to https://kutt.it/uYkRIb, it fails to preview and remains a static link without a preview.

This is new behavior, as for many years until now both kutt.it and custom domain links shortened through Kutt embedded/previewed just fine.

Munaf-Divan commented 1 year ago

Hey @DananFlander, I might be wrong here, but I think it's more of a discord issue than it is of Kutt.

ukdaaan commented 1 year ago

@DananFlander I've tried this with my own hosted instance and it works as expected, i don't have an account on the primary kutt.it instance so I can't test it there.

You're more than welcome to try upload a screenshot to uk.thot.cc and see if you get the same issues with the kutt.it instance when shortening the URL.


Example Below

Screenshot 2023-10-29 at 17 45 17
DananFlander commented 1 year ago

@ukdaaan I was able to successfully upload an image to uk.thot.cc, shorten the link on kutt.it, and retrieve an embed for both versions, but emulating those same steps, it does not work for my image host (v.gy), as seen here:

image

Is there a way to determine where in the handoff between v.gy and kutt.it it's going wrong?

ukdaaan commented 1 year ago

I don't know for certain however I'd start with checking the meta tags for the i.vgy.me domain, it sounds like the image might not be presented and therefore discord might not follow the 301 redirect. I know there's been some changes based on how Discord now handles twitter.com urls.