From 124cb5347e3ef72ca020780d1928e31c22fca8ea Mon Sep 17 00:00:00 2001 From: quix0r Date: Thu, 20 Jun 2013 20:52:57 +0000 Subject: [PATCH] MySQLi requires at least a link resource for all its functions/methods --- inc/db/lib-mysqli.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/db/lib-mysqli.php b/inc/db/lib-mysqli.php index 85e9c0a03c..02d0c8e5da 100644 --- a/inc/db/lib-mysqli.php +++ b/inc/db/lib-mysqli.php @@ -276,7 +276,7 @@ function sqlFreeResult ($resource) { // Get id from last INSERT command and secure id function getSqlInsertId () { if (!isSqlLinkUp()) return FALSE; - return bigintval(mysqli_insert_id()); + return bigintval(mysqli_insert_id(getSqlLink())); } // Escape a string for the database -- 2.39.5