use max.min

This commit is contained in:
Baris Usakli
2018-11-09 16:48:34 -05:00
parent 2ee743d65c
commit 2c5157aeaa

View File

@@ -42,7 +42,7 @@ function searchInContent(data, callback) {
var matchCount = 0;
var pids;
var metadata;
var itemsPerPage = data.itemsPerPage || 10;
var itemsPerPage = Math.min(data.itemsPerPage || 10, 100);
async.waterfall([
function (next) {
async.parallel({