From c1abdc29c425b143462bfd0b8d1dd6bb7a4e66a0 Mon Sep 17 00:00:00 2001 From: Menci Date: Tue, 13 Dec 2016 08:34:22 +0800 Subject: [PATCH] Fix Model.query return no data when querying a interval --- models/common.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/common.js b/models/common.js index 4aa50a0..5bf70bc 100644 --- a/models/common.js +++ b/models/common.js @@ -88,7 +88,7 @@ class Model { } static async query(paginate, where, order) { - if (paginate && !paginate.pageCnt) return []; + if (paginate && !Array.isArray(paginate) && !paginate.pageCnt) return []; let options = { where: where,