From: Hugo Villeneuve Date: Sat, 27 Feb 2021 21:35:19 +0000 (-0500) Subject: Fix bug when adding imported new entry X-Git-Url: http://gitweb.hugovil.com/?a=commitdiff_plain;h=4acf917fa54f1fbf9be4b0bec3dcf4405a9bc975;p=php-addressbook.git Fix bug when adding imported new entry --- diff --git a/include/address.class.php b/include/address.class.php index 8715055..69c1b6c 100644 --- a/include/address.class.php +++ b/include/address.class.php @@ -109,7 +109,7 @@ function saveAddress($addr_array, $group_name = "") { $sql = "SELECT max(id) max_id from $table"; $result = mysqli_query($db, $sql); - $rec = mysqli_fetch_array($db. $result); + $rec = mysqli_fetch_array($result); $id = $rec['max_id']; if(!isset($addr_array['id']) && $group_name) {