ensl_gathers/lib/user/helper.js
AngelRionCervi 3c253a7c4b Added graphic element to show the picking pattern (#142)
* added picking pattern

* removed all changes to helpers
2019-06-10 08:55:46 +02:00

19 lines
385 B
JavaScript

"use strict";
var User = require("../user/user");
var client = require("../ensl/client")();
var async = require("async");
var getRandomUser = callback => {
let id = Math.floor(Math.random() * 5000) + 1;
User.find(id, function (error, user) {
if (error) return getRandomUser(callback);
return callback(error, user);
})
};
module.exports = {
getRandomUser: getRandomUser
};