From 1223840b4aa04a4511c3d27250d602881f65d7bd Mon Sep 17 00:00:00 2001 From: Jari Turkia Date: Tue, 8 Oct 2024 22:58:14 +0300 Subject: [PATCH] bugfix: pg_escape_string() in serendipity_db_escape_string() works again --- include/db/postgres.inc.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/db/postgres.inc.php b/include/db/postgres.inc.php index ec32b3831..12ac0c335 100644 --- a/include/db/postgres.inc.php +++ b/include/db/postgres.inc.php @@ -89,7 +89,9 @@ function serendipity_db_reconnect() { * @return string output string */ function serendipity_db_escape_string($string) { - return pg_escape_string($string); + global $serendipity; + + return pg_escape_string($serendipity['dbConn'], $string); } /**