Remove outdated adlists.list check and fix empty adlists error message

Signed-off-by: Mcat12 <newtoncat12@yahoo.com>
pull/2831/head
Mcat12 5 years ago
parent 2b5033e732
commit 3ebd43ebf0
No known key found for this signature in database
GPG Key ID: ABB8FC9789AF524D

@ -102,15 +102,6 @@ if ($blocklistglob === array()) {
die("[ERROR] There are no domain lists generated lists within <code>/etc/pihole/</code>! Please update gravity by running <code>pihole -g</code>, or repair Pi-hole using <code>pihole -r</code>.");
}
// Set location of adlists file
if (is_file("/etc/pihole/adlists.list")) {
$adLists = "/etc/pihole/adlists.list";
} elseif (is_file("/etc/pihole/adlists.default")) {
$adLists = "/etc/pihole/adlists.default";
} else {
die("[ERROR] File not found: <code>/etc/pihole/adlists.list</code>");
}
// Get possible non-standard location of FTL's database
$FTLsettings = parse_ini_file("/etc/pihole/pihole-FTL.conf");
if (isset($FTLsettings["GRAVITYDB"])) {
@ -134,7 +125,7 @@ while ($row = $adlistResults->fetchArray()) {
}
if (empty($adlistsUrls))
die("[ERROR]: There are no adlists configured");
die("[ERROR]: There are no adlists enabled");
// Get total number of blocklists (Including Whitelist, Blacklist & Wildcard lists)
$adlistsCount = count($adlistsUrls) + 3;

Loading…
Cancel
Save