From c1145f3b16f6567be51dd2708f3a4db55aa0e715 Mon Sep 17 00:00:00 2001 From: Urban Müller Date: Tue, 21 Apr 2020 18:53:47 +0200 Subject: accept LIMIT 0 --- it_dbi.class | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/it_dbi.class b/it_dbi.class index b06a3ea..3620018 100644 --- a/it_dbi.class +++ b/it_dbi.class @@ -358,7 +358,7 @@ function _where($params) else if ($field == "LIMIT") { if ($value !== false) # only false no null; uninitialized values should not unintentionally omit LIMIT - $stringquery .= " LIMIT " . (it::match('^[ ,\d]+$', $value) ?: it::error(['title' => "invalid LIMIT $value", 'body' => $params]) + 0); + $stringquery .= " LIMIT " . (it::match('^[ ,\d]+$', $value) ?? it::error(['title' => "invalid LIMIT $value", 'body' => $params]) + 0); } else { -- cgit v1.2.3