Embed link parsing issue

(#308) Bug Fixed embeds markdown

Summary

Hello there, I meant to report this a few days ago but I forgot. When I post specific embeds with a ' in the link it fails to properly hide the link.

Steps to reproduce

Go to GIF selection -> select gif with ' in link

Logs or screenshots (optional)

I think this isn't only related to the GIF selector but it's an overall link issue. Here is one link to test: https://tenor.com/view/smug-frieren-frieren-beyond-journey's-end-sousou-no-frieren-anime-gif-7880495752394939238 image
  • 554043096-5e917ea3-9dbf-4170-8caf-99739b198431.png

    554043096-5e917ea3-9dbf-4170-8caf-99739b198431.png

    1080×1065 | 756 kB

3 comments

Sign in with Fluxer to comment and vote.
Comment by @Sylos-Creator
RexSystem 1 vote originally by @Sylos-Creator on GitHub
This looks like a url encoding issue and string escapes. I can try to take a look at this one if allowed. I suspect just str replace into url encoded form would work as a workaround but it's not a super user friendly workaround. the url encoded version of this that probably wouldn't break in the UI is this: https://tenor.com/view/smug-frieren-frieren-beyond-journey%27s-end-sousou-no-frieren-anime-gif-7880495752394939238
Comment by @Ly-sec
RexSystem 1 vote originally by @Ly-sec on GitHub OP
This looks like a url encoding issue and string escapes. I can try to take a look at this one if allowed. I suspect just str replace into url encoded form would work as a workaround but it's not a super user friendly workaround. the url encoded version of this that probably wouldn't break in the UI is this: https://tenor.com/view/smug-frieren-frieren-beyond-journey%27s-end-sousou-no-frieren-anime-gif-7880495752394939238
That doesn't look that terrible to me to be fair. Just checked how discord handles it and in fact they do the exact same thing that you mentioned :) That's the link from discord
https://tenor.com/view/smug-frieren-frieren-beyond-journey%27s-end-sousou-no-frieren-anime-gif-7880495752394939238
Comment by @erayerdin
RexSystem 1 vote originally by @erayerdin on GitHub
image Same.
  • 562076837-804c76dc-c199-478f-a196-3c9df4a55697.png

    562076837-804c76dc-c199-478f-a196-3c9df4a55697.png

    1181×355 | 59 kB