From b2cccada235070cf4d11e75b488f501608936e83 Mon Sep 17 00:00:00 2001 From: dbroqua Date: Thu, 11 Apr 2019 13:13:01 +0200 Subject: [PATCH] Debug --- middleware/VegetableTypes.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/middleware/VegetableTypes.js b/middleware/VegetableTypes.js index 05835c8..9698bbf 100644 --- a/middleware/VegetableTypes.js +++ b/middleware/VegetableTypes.js @@ -31,6 +31,7 @@ class VegetableTypes { let k = 0 for (k = 0; k < vegetables.length; k += 1) { if (type.Vegetables[j].name < vegetables[k]) { + console.log('Break at:', k) break } } @@ -41,7 +42,7 @@ class VegetableTypes { res.push(type) } - callback(null, { count: items.count, rows: res }) + callback(null, { count: res.length, rows: res }) }) .catch((e) => { console.log('ERR:', e)