From 7ef00a2c6a7bbd2ec16a037ee2268d37d747449b Mon Sep 17 00:00:00 2001 From: Jeremy Fincher Date: Tue, 31 Aug 2004 14:54:37 +0000 Subject: [PATCH] Handled reply.withNoticeWhenPrivate appropriately. --- src/callbacks.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/callbacks.py b/src/callbacks.py index ad5d4c68b..d8be964ce 100644 --- a/src/callbacks.py +++ b/src/callbacks.py @@ -161,11 +161,6 @@ def reply(msg, s, prefixName=True, private=None, target = msg.nick else: target = to - # XXX: User value for reply.withNoticeWhenPrivate. - if conf.supybot.reply.withNoticeWhenPrivate(): # global, no getConfig. - if not ircutils.isChannel(target): - # to=channel, private=True (see RSS for an example) - notice = True if to is None: to = msg.nick # Ok, now let's make the payload: @@ -176,6 +171,9 @@ def reply(msg, s, prefixName=True, private=None, # Let's may sure we don't do, "#channel: foo.". if not ircutils.isChannel(to): s = '%s: %s' % (to, s) + if not ircutils.isChannel(target): + if conf.supybot.reply.withNoticeWhenPrivate(): + notice = True # And now, let's decide whether it's a PRIVMSG or a NOTICE. msgmaker = ircmsgs.privmsg if notice: