summaryrefslogtreecommitdiff
path: root/searx/plugins/hostname_replace.py
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarit.de>2024-06-07 15:38:09 +0200
committerMarkus Heiser <markus.heiser@darmarIT.de>2024-08-08 11:58:32 +0200
commitdcf95644c6ba7308f521ca14dbed79127404af7f (patch)
tree940891fe01257b49d1f61284e9b5bc41e428e04f /searx/plugins/hostname_replace.py
parent0cfed94b08ad6c767dceab89b36a62fc9785a534 (diff)
[breaking change] drop deprecated hostname_replace plugin
The successor is “hostname plugin” from PR: - https://github.com/searxng/searxng/pull/3463 --- Revert "[refactor] hostnames plugin: add fallback for old hostname_replace plugin" This reverts commit f5eb56b63f250c7804e5e1cf4426e550bc933906. Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searx/plugins/hostname_replace.py')
-rw-r--r--searx/plugins/hostname_replace.py35
1 files changed, 0 insertions, 35 deletions
diff --git a/searx/plugins/hostname_replace.py b/searx/plugins/hostname_replace.py
deleted file mode 100644
index 48900a3f9..000000000
--- a/searx/plugins/hostname_replace.py
+++ /dev/null
@@ -1,35 +0,0 @@
-# SPDX-License-Identifier: AGPL-3.0-or-later
-# pylint: disable=missing-module-docstring
-
-from flask_babel import gettext
-from searx.plugins import logger
-
-name = gettext('Hostname replace')
-description = "Deprecated / contact system admin to configure 'Hostnames plugin'!!"
-default_on = False
-preference_section = 'general'
-
-plugin_id = 'hostname_replace'
-logger = logger.getChild(plugin_id)
-
-REPORTED = False
-
-
-def deprecated_msg():
- global REPORTED # pylint: disable=global-statement
- if REPORTED:
- return
- logger.error(
- "'Hostname replace' plugin is deprecated and will be dropped soon!"
- " Configure 'Hostnames plugin':"
- " https://docs.searxng.org/src/searx.plugins.hostnames.html"
- )
- REPORTED = True
-
-
-def on_result(_request, _search, result):
- # pylint: disable=import-outside-toplevel, cyclic-import
- from searx.plugins.hostnames import on_result as hostnames_on_result
-
- deprecated_msg()
- return hostnames_on_result(_request, _search, result)