Merge branch 'master' of gitfap.de:keinBot/keinBotv2
This commit is contained in:
commit
33b82336db
22
src/trigger/del.js
Normal file
22
src/trigger/del.js
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
module.exports = (bot) => {
|
||||||
|
var del = (e, args) => {
|
||||||
|
var tmp_channel = bot.getChannel(e.channel.getName(), e.network).names;
|
||||||
|
getUserlevel(e, e.user.getNick(), tmp_channel, (cb) => {
|
||||||
|
if(cb.level >= 100) {
|
||||||
|
var id = orig.split(' ')[1];
|
||||||
|
sql.query("delete from `f0ck`.`items` where `id` = ?", id).on('end', () => {
|
||||||
|
e.reply("f0ck "+id+" deleted");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else
|
||||||
|
e.reply("no permission");
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
bot.addCmd({
|
||||||
|
name: 'spec',
|
||||||
|
level: 100,
|
||||||
|
func: spec,
|
||||||
|
desc: 'delete f0rk'
|
||||||
|
});
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user