aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engine/lib/database.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/engine/lib/database.php b/engine/lib/database.php
index 0979592c0..fef31e682 100644
--- a/engine/lib/database.php
+++ b/engine/lib/database.php
@@ -153,6 +153,9 @@
throw new DatabaseException(mysql_error($dblink) . " QUERY: " . $query);
if (empty($resultarray)) {
+ if ((isset($CONFIG->debug)) && ($CONFIG->debug==true))
+ error_log("WARNING: DB query \"$query\" returned no results.");
+
return false;
}
return $resultarray;
@@ -186,7 +189,10 @@
if (mysql_errno($dblink))
throw new DatabaseException(mysql_error($dblink) . " QUERY: " . $query);
-
+
+ if ((isset($CONFIG->debug)) && ($CONFIG->debug==true))
+ error_log("WARNING: DB query \"$query\" returned no results.");
+
return false;
}