replacements: strip spaces from replacement URL.

Fix a handful of replacements having a replacement URL with a space in front or at the end.
This caused problems when searching by replacement URL.
This commit is contained in:
evazion
2022-11-21 17:41:15 -06:00
parent 2d2b465ef8
commit 1a9718250f
2 changed files with 15 additions and 1 deletions

View File

@@ -27,7 +27,7 @@ class PostReplacementProcessor
elsif Source::URL.page_url(image_url).present?
canonical_url = image_url
else
canonical_url = replacement.replacement_url
canonical_url = replacement.replacement_url.strip
end
replacement.replacement_url = canonical_url