also bingbot and yandex don't need to see deep archives of weird searches

This commit is contained in:
Shish 2020-02-06 12:49:11 +00:00
parent 81ebc51257
commit 45347279ce

View File

@ -46,13 +46,18 @@ class Index extends Extension
$fast_page_limit = 500;
if (
SPEED_HAX && strstr($_SERVER["HTTP_USER_AGENT"], "Googlebot") !== false
SPEED_HAX
&& (
strstr($_SERVER["HTTP_USER_AGENT"], "Googlebot") !== false
|| strstr($_SERVER["HTTP_USER_AGENT"], "YandexBot") !== false
|| strstr($_SERVER["HTTP_USER_AGENT"], "bingbot") !== false
)
&& (
$count_search_terms > 1
|| ($count_search_terms == 1 && $search_terms[0][0] == "-")
)
) {
// googlebot loves searching for weird combinations of tags...
// bots love searching for weird combinations of tags...
$fast_page_limit = 10;
}