diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-11-21 19:03:07 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-21 19:03:07 +0100 |
commit | a60b602ade955c8ce620facae160ffabd7893d4b (patch) | |
tree | c3d5a014704043a27da321b9f801a0171d7f53b0 /app/services | |
parent | 2edf6d81cba25555814046d7b9f260872c2c9545 (diff) |
Fix OEmbed discovery not handling different URL variants in query (#12439)
Fix #12433
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/fetch_oembed_service.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/fetch_oembed_service.rb b/app/services/fetch_oembed_service.rb index 4f8498c62..76d971bc5 100644 --- a/app/services/fetch_oembed_service.rb +++ b/app/services/fetch_oembed_service.rb @@ -58,7 +58,7 @@ class FetchOEmbedService url_domain = Addressable::URI.parse(@url).normalized_host endpoint_hash = { - endpoint: @endpoint_url.gsub(URI.encode_www_form_component(@url), '{url}'), + endpoint: @endpoint_url.gsub(/(=(http[s]?(%3A|:)(\/\/|%2F%2F)))([^&]*)/i, '={url}'), format: @format, } |