mirror of
https://github.com/pi-hole/web.git
synced 2025-12-24 12:48:29 +00:00
Use simpler regex format for wildcards
Use `\.?domain\.com$` instead of `((^)|(\.))domain\.com$` Signed-off-by: Mcat12 <newtoncat12@yahoo.com>
This commit is contained in:
@@ -37,7 +37,7 @@ switch($type) {
|
||||
// Escape "." so it won't be interpreted as the wildcard character
|
||||
$domain = str_replace(".","\.",$_POST['domain']);
|
||||
// Add regex filter for legacy wildcard behavior
|
||||
add_regex("((^)|(\.))".$domain."$");
|
||||
add_regex("\.?".$domain."$");
|
||||
break;
|
||||
case "regex":
|
||||
add_regex($_POST['domain']);
|
||||
|
||||
Reference in New Issue
Block a user