eric6/WebBrowser/OpenSearch/OpenSearchReader.py

changeset 8205
4a0f1f896341
parent 8143
2c730d5fd177
diff -r fd477cded1c1 -r 4a0f1f896341 eric6/WebBrowser/OpenSearch/OpenSearchReader.py
--- a/eric6/WebBrowser/OpenSearch/OpenSearchReader.py	Thu Apr 08 17:27:12 2021 +0200
+++ b/eric6/WebBrowser/OpenSearch/OpenSearchReader.py	Thu Apr 08 18:27:47 2021 +0200
@@ -75,8 +75,7 @@
                 
                 if (
                     (not type_ or
-                     type_ == "text/html" or
-                     type_ == "application/xhtml+xml") and
+                     type_ in ("text/html", "application/xhtml+xml")) and
                     engine.searchUrlTemplate()
                 ):
                     continue
@@ -112,8 +111,7 @@
                     engine.setSuggestionsMethod(method)
                 elif (
                     not type_ or
-                    type_ == "text/html" or
-                    type_ == "application/xhtml+xml"
+                    type_ in ("text/html", "application/xhtml+xml")
                 ):
                     engine.setSearchUrlTemplate(url)
                     engine.setSearchParameters(parameters)

eric ide

mercurial