From c53436ab3fed7c171fa0732de089fdf4c39ba8fb Mon Sep 17 00:00:00 2001 From: Adam Warner Date: Wed, 13 May 2020 23:38:43 +0100 Subject: [PATCH] Also do this from the query log page Signed-off-by: Adam Warner --- scripts/pi-hole/php/database.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/pi-hole/php/database.php b/scripts/pi-hole/php/database.php index 82f10485..0df4c39f 100644 --- a/scripts/pi-hole/php/database.php +++ b/scripts/pi-hole/php/database.php @@ -136,7 +136,7 @@ function add_to_table($db, $table, $domains, $comment=null, $wildcardstyle=false $querystr = "INSERT OR IGNORE INTO $table ($field,comment) VALUES (:$field, :comment);"; $bindcomment = true; } else { - $querystr = "INSERT OR IGNORE INTO $table ($field,comment,type) VALUES (:$field, :comment, $type);"; + $querystr = "REPLACE INTO $table ($field,comment,type) VALUES (:$field, :comment, $type);"; $bindcomment = true; } $stmt = $db->prepare($querystr);