From 385894b5ac69da0bfa41b1601e7082ffdeff0961 Mon Sep 17 00:00:00 2001 From: pyoor Date: Mon, 30 Jul 2018 10:36:46 -0400 Subject: [PATCH] Remove incorrect check in random.pick --- lib/random/random.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lib/random/random.js b/lib/random/random.js index 403a59a..3a86f64 100644 --- a/lib/random/random.js +++ b/lib/random/random.js @@ -114,11 +114,6 @@ class random { * @returns {*} */ static pick (obj) { - if (!(Array.isArray(obj) || typeof obj === 'function')) { - logger.traceback() - throw new TypeError(`random.pick() received invalid object: (${obj})`) - } - if (typeof obj === 'function') { return obj() } else if (Array.isArray(obj)) {