From 6ec4adb306ec0822f7d172501d20fbfd82b5a125 Mon Sep 17 00:00:00 2001 From: Craig Cook Date: Wed, 31 Jul 2024 15:04:41 -0700 Subject: [PATCH] Add vanity URL redirect for Nothing Personal page [fix #14944] (#14945) --- bedrock/firefox/redirects.py | 1 + bedrock/mozorg/redirects.py | 2 ++ tests/redirects/map_globalconf.py | 3 +++ 3 files changed, 6 insertions(+) diff --git a/bedrock/firefox/redirects.py b/bedrock/firefox/redirects.py index f9b8abb5526..6244d7f7d46 100644 --- a/bedrock/firefox/redirects.py +++ b/bedrock/firefox/redirects.py @@ -598,4 +598,5 @@ def mobile_app(request, *args, **kwargs): redirect(r"^firefox/privacy/products/?$", "products.landing"), redirect(r"^firefox/privacy/safe-passwords/?$", "firefox.features.password-manager"), redirect(r"^firefox/privacy/book/?$", "https://support.mozilla.org/kb/how-stay-safe-web"), + redirect(r"^firefox/nothingpersonal/?$", "firefox.nothing-personal.index"), ) diff --git a/bedrock/mozorg/redirects.py b/bedrock/mozorg/redirects.py index c0264dde5af..9e9a6242b49 100644 --- a/bedrock/mozorg/redirects.py +++ b/bedrock/mozorg/redirects.py @@ -567,4 +567,6 @@ def decider(request, **kwargs): # redirects that don't need a lang code prefix redirect(r"^diversity/?$", "mozorg.diversity.2022.index", locale_prefix=False), redirect(r"^webvision/?$", "mozorg.about.webvision.summary", locale_prefix=True, prepend_locale=False), + # issue 14944 + redirect(r"^nothing-?personal/?$", "firefox.nothing-personal.index"), ) diff --git a/tests/redirects/map_globalconf.py b/tests/redirects/map_globalconf.py index 3fa2fb164af..26eb5f5b0b6 100644 --- a/tests/redirects/map_globalconf.py +++ b/tests/redirects/map_globalconf.py @@ -1301,5 +1301,8 @@ url_test("/firefox/privacy/products/", "/products/"), url_test("/firefox/privacy/safe-passwords/", "/firefox/features/password-manager/"), url_test("/firefox/privacy/book/", "https://support.mozilla.org/kb/how-stay-safe-web"), + # issue 14944 + url_test("/{nothing-personal,nothingpersonal}/", "/firefox/nothing-personal/"), + url_test("/firefox/nothingpersonal/", "/firefox/nothing-personal/"), ) )