From 8e4e4534b9cff865fe61101dcb5fd207405d8329 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Wed, 12 Dec 2007 20:33:25 +0000 Subject: [PATCH] Improve ExecSqlParam --- include/postgres.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/postgres.php b/include/postgres.php index 4e55b38b1..e5ab89dd8 100644 --- a/include/postgres.php +++ b/include/postgres.php @@ -159,14 +159,14 @@ function ExecSqlParam($p_connection, $p_string,$p_array) { //---- pg_set_client_encoding($p_connection,'latin1'); - ob_start(); + if (!DEBUG ) ob_start(); $ret=pg_query_params($p_connection,$p_string,$p_array); if ( ! $ret ) { - ob_clean(); - $r=$string."array ".var_export($p_array,TRUE); + if (!DEBUG )ob_clean(); + $r=$p_string."array ".var_export($p_array,TRUE); throw new Exception (" SQL ERROR $r",1); } - ob_flush(); + if (!DEBUG ) ob_flush(); return $ret; }