40 lines
1.7 KiB
Diff
40 lines
1.7 KiB
Diff
From: uazo <uazo@users.noreply.github.com>
|
|
Date: Sun, 8 Oct 2023 16:04:56 +0000
|
|
Subject: Disable ranker_url_fetcher
|
|
|
|
License: GPL-2.0-or-later - https://spdx.org/licenses/GPL-2.0-or-later.html
|
|
---
|
|
.../translate/core/browser/translate_ranker_impl.cc | 10 +++++-----
|
|
1 file changed, 5 insertions(+), 5 deletions(-)
|
|
|
|
diff --git a/components/translate/core/browser/translate_ranker_impl.cc b/components/translate/core/browser/translate_ranker_impl.cc
|
|
--- a/components/translate/core/browser/translate_ranker_impl.cc
|
|
+++ b/components/translate/core/browser/translate_ranker_impl.cc
|
|
@@ -94,11 +94,11 @@ const char kDefaultTranslateRankerModelURL[] =
|
|
#endif
|
|
|
|
BASE_FEATURE(kTranslateRankerQuery,
|
|
- "TranslateRankerQuery",
|
|
- base::FEATURE_ENABLED_BY_DEFAULT);
|
|
+ "TranslateRankerQuery", // disable
|
|
+ base::FEATURE_DISABLED_BY_DEFAULT); // by default
|
|
BASE_FEATURE(kTranslateRankerEnforcement,
|
|
- "TranslateRankerEnforcement",
|
|
- base::FEATURE_ENABLED_BY_DEFAULT);
|
|
+ "TranslateRankerEnforcement", // disable
|
|
+ base::FEATURE_DISABLED_BY_DEFAULT); // by default
|
|
|
|
BASE_FEATURE(kTranslateRankerPreviousLanguageMatchesOverride,
|
|
"TranslateRankerPreviousLanguageMatchesOverride",
|
|
@@ -234,7 +234,7 @@ bool TranslateRankerImpl::ShouldOfferTranslation(
|
|
// absence of a model or if enforcement is disabled. As this is ranker is
|
|
// subsumed into a more general assist ranker, this default will go away
|
|
// (or become False).
|
|
- const bool kDefaultResponse = true;
|
|
+ const bool kDefaultResponse = false;
|
|
|
|
translate_event->set_ranker_request_timestamp_sec(
|
|
(base::TimeTicks::Now() - base::TimeTicks()).InSeconds());
|
|
--
|
|
2.25.1
|