diff options
| -rw-r--r-- | vendor/user-agent.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vendor/user-agent.js b/vendor/user-agent.js index 977fde46..95b252ae 100644 --- a/vendor/user-agent.js +++ b/vendor/user-agent.js @@ -43,7 +43,8 @@ function rnd(a, b) { if (Object.prototype.toString.call(a) === "[object Array]") { //returns a random element from array (a), even weighting - return a[Math.floor(Math.random() * a.length)]; + var faker = require('../'); + return faker.random.arrayElement(a); } if (a && typeof a === 'object') { |
