2019-09-18T23:18:27.862Z [26413] - error: message=Cannot read property 'isBanned' of undefined, stack=TypeError: Cannot read property 'isBanned' of undefined
// Error happens here
// Check ban state of user, reject if banned
user.bans.isBanned(uid, function(err, banned) {
callback(err || banned ? new Error("banned") : null, uid);
});
// This works but of course I want to check if user is banned
// callback(null, uid);
Hi,
I'm getting this error:
2019-09-18T23:18:27.862Z [26413] - error: message=Cannot read property 'isBanned' of undefined, stack=TypeError: Cannot read property 'isBanned' of undefined
Any idea what's causing the error?
Thanks!