banOutput option in command [#460]

This commit is contained in:
reality 2013-05-27 17:45:30 +00:00
parent e1ea156a41
commit 429eafd8e4
2 changed files with 5 additions and 2 deletions

View File

@ -24,7 +24,9 @@ var command = function(dbot) {
dbot.api.ignore.isUserIgnoring(event.server, event.user, commandName, function(isIgnoring) { dbot.api.ignore.isUserIgnoring(event.server, event.user, commandName, function(isIgnoring) {
dbot.api.ignore.isUserBanned(event.server, event.user, commandName, function(isBanned) { dbot.api.ignore.isUserBanned(event.server, event.user, commandName, function(isBanned) {
if(isBanned) { if(isBanned) {
event.reply(dbot.t('command_ban', {'user': event.user})); if(this.config.banOutput === true && commandName != '~') {
event.reply(dbot.t('command_ban', {'user': event.user}));
}
} else if(!hasAccess) { } else if(!hasAccess) {
if(this.config.accessOutput) { if(this.config.accessOutput) {
event.reply(dbot.t('access_denied', { 'user': event.user })); event.reply(dbot.t('access_denied', { 'user': event.user }));

View File

@ -2,5 +2,6 @@
"ignorable": false, "ignorable": false,
"dependencies": [ "event", "ignore", "users" ], "dependencies": [ "event", "ignore", "users" ],
"useNickserv": false, "useNickserv": false,
"accessOutput": false "accessOutput": false,
"banOutput": false
} }