From 413e13824def564cca3c514a72b0f76b15ec4a6f Mon Sep 17 00:00:00 2001 From: urlbot Date: Fri, 5 Dec 2014 15:05:37 +0100 Subject: [PATCH] add optional filtering for show-blacklist --- plugins.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins.py b/plugins.py index 46248c5..9dbb11b 100644 --- a/plugins.py +++ b/plugins.py @@ -426,8 +426,8 @@ def command_show_blacklist(args): if 'register' == args: return { 'name': 'show-blacklist', - 'desc': 'show the current URL blacklist', - 'args': ('data', 'reply_user'), + 'desc': 'show the current URL blacklist, optionally filtered', + 'args': ('data', 'reply_user', 'argv1'), 'ratelimit_class': RATE_GLOBAL } @@ -438,6 +438,7 @@ def command_show_blacklist(args): 'msg': [ args['reply_user'] + ': URL blacklist: ' + b for b in conf('url_blacklist') + if not args['argv1'] or args['argv1'] in b ] }