aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/helpers.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/helpers.js b/lib/helpers.js
index 930fce1e..635c4ecc 100644
--- a/lib/helpers.js
+++ b/lib/helpers.js
@@ -83,7 +83,7 @@ var Helpers = function (faker) {
* @param {array} o
*/
self.shuffle = function (o) {
- if (o.length === 0) {
+ if (typeof o === 'undefined' || o.length === 0) {
return [];
}
o = o || ["a", "b", "c"];