f0ckv1/src/trigger/user.js
2016-09-08 15:42:38 +00:00

18 lines
427 B
JavaScript

module.exports = (bot, trigger, lib) => {
trigger.add({
name: 'user',
call: /^\!user( \@.*)?/i,
level: 0,
active: 1,
func: (e) => {
if(!(user = e.message.match(/^\!user( +@(.*))?/i)[2]))
user = e.user.getNick();
else
user = user.trim();
bot.whois(user, e.network, (err, data) => {
e.reply(data);
});
},
desc: 'get Userdata'
});
};