Change INSERT statement to INSERT OR IGNORE on adlist management as a workaround for now

Signed-off-by: Adam Warner <me@adamwarner.co.uk>
This commit is contained in:
Adam Warner
2020-06-06 18:27:22 +01:00
parent efd9281fa4
commit 5b71dab0c7

View File

@@ -746,7 +746,7 @@ if ($_POST['action'] == 'get_groups') {
$total = count($addresses);
$added = 0;
$stmt = $db->prepare('INSERT INTO adlist (address,comment) VALUES (:address,:comment)');
$stmt = $db->prepare('INSERT OR IGNORE INTO adlist (address,comment) VALUES (:address,:comment)');
if (!$stmt) {
throw new Exception('While preparing statement: ' . $db->lastErrorMsg());
}