mirror of
https://github.com/Nezumi-2711/cloudflare-gateway-pihole-scripts.git
synced 2026-09-22 20:01:04 +00:00
Remove empty lines from the user-defined list URLs
Possible fix for #33
This commit is contained in:
+3
-2
@@ -33,11 +33,12 @@ export const LIST_TYPE = {
|
||||
};
|
||||
|
||||
export const USER_DEFINED_ALLOWLIST_URLS = process.env.ALLOWLIST_URLS
|
||||
? process.env.ALLOWLIST_URLS.split("\n")
|
||||
// .filter(x => x) removes empty items from the URL arrays
|
||||
? process.env.ALLOWLIST_URLS.split("\n").filter(x => x)
|
||||
: undefined;
|
||||
|
||||
export const USER_DEFINED_BLOCKLIST_URLS = process.env.BLOCKLIST_URLS
|
||||
? process.env.BLOCKLIST_URLS.split("\n")
|
||||
? process.env.BLOCKLIST_URLS.split("\n").filter(x => x)
|
||||
: undefined;
|
||||
|
||||
export const RECOMMENDED_ALLOWLIST_URLS = [
|
||||
|
||||
Reference in New Issue
Block a user