From a5ad77780dc4a02f40ef5f14672477e28807933c Mon Sep 17 00:00:00 2001 From: totoro Date: Mon, 3 Apr 2017 22:38:40 +0200 Subject: [PATCH] fix the empty WHERE clause by (1 = 1) which always true --- controller/hk_sql_utils.anubis | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/controller/hk_sql_utils.anubis b/controller/hk_sql_utils.anubis index aa47cdb..9320946 100644 --- a/controller/hk_sql_utils.anubis +++ b/controller/hk_sql_utils.anubis @@ -17,13 +17,13 @@ public define String )= if referer is { - no_referer then "", + no_referer then " (1 = 1) ", hk_referer(referer_table, referer_row_id, fk_table, fk_column) then if referer_table = table_name then "id = " +referer_row_id else if fk_column:table_columns then fk_column + " = " + referer_row_id else - "", + " (1 = 1) ", } . -- libgit2 0.21.4