mirror of
https://github.com/revanced/revanced-patches.git
synced 2025-12-06 17:41:26 +01:00
fix(YouTube - Check watch history domain name resolution): Fix false positive warning message if the internet connection fails halfway into the DNS check
This commit is contained in:
@@ -61,7 +61,11 @@ public class CheckWatchHistoryDomainNameResolutionPatch {
|
||||
// Prevent this false positive by verify youtube.com resolves.
|
||||
// If youtube.com does not resolve, then it's not a watch history domain resolving error
|
||||
// because the entire app will not work since no domains are resolving.
|
||||
if (!domainResolvesToValidIP("youtube.com")
|
||||
String domainYouTube = "youtube.com";
|
||||
if (!domainResolvesToValidIP(domainYouTube)
|
||||
|| domainResolvesToValidIP(HISTORY_TRACKING_ENDPOINT)
|
||||
// Check multiple times, so a false positive from a flaky connection is almost impossible.
|
||||
|| !domainResolvesToValidIP(domainYouTube)
|
||||
|| domainResolvesToValidIP(HISTORY_TRACKING_ENDPOINT)) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -45,7 +45,7 @@ Second \"item\" text"</string>
|
||||
<string name="revanced_check_environment_not_near_patch_time_invalid">APK build date is corrupted</string>
|
||||
</patch>
|
||||
<patch id="misc.dns.checkWatchHistoryDomainNameResolutionPatch">
|
||||
<string name="revanced_check_watch_history_domain_name_dialog_title">Warning</string>
|
||||
<string name="revanced_check_watch_history_domain_name_dialog_title">ReVanced Notice</string>
|
||||
<string name="revanced_check_watch_history_domain_name_dialog_message">Your watch history is not being saved.<br><br>This most likely is caused by a DNS ad blocker or network proxy.<br><br>To fix this, whitelist <b>s.youtube.com</b> or turn off all DNS blockers and proxies.</string>
|
||||
<string name="revanced_check_watch_history_domain_name_dialog_ignore">Do not show again</string>
|
||||
</patch>
|
||||
|
||||
Reference in New Issue
Block a user