From f8f6e5f37f54147b87c62636746b2d2c691bd9f4 Mon Sep 17 00:00:00 2001 From: Aevann Date: Thu, 24 Aug 2023 03:57:03 +0300 Subject: [PATCH] fix cnn urls broken bc of amp stripping --- files/helpers/sanitize.py | 1 + 1 file changed, 1 insertion(+) diff --git a/files/helpers/sanitize.py b/files/helpers/sanitize.py index a128ee29d2..70ceb8d288 100644 --- a/files/helpers/sanitize.py +++ b/files/helpers/sanitize.py @@ -764,6 +764,7 @@ def normalize_url(url): .replace("/giphy.gif", "/giphy.webp") \ .replace('https://www.google.com/amp/s/', 'https://') \ .replace('https://amp.', 'https://') \ + .replace('https://cnn.com/cnn/', 'https://edition.cnn.com/') \ .replace('/amp/', '/') \ if url.endswith('.amp'):