From 33af03a58a4bf178874b8faea4b2c99b4f7535db Mon Sep 17 00:00:00 2001 From: Jon Bergli Heier Date: Mon, 16 Aug 2010 17:44:59 +0200 Subject: tracking: Assign label at the correct place in lc_callback(). --- modules/tracking.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/tracking.py b/modules/tracking.py index aa57763..a293670 100644 --- a/modules/tracking.py +++ b/modules/tracking.py @@ -301,6 +301,7 @@ class Module: session = Session() consignments = session.query(Consignment).filter(Consignment.channel.in_(config.get(self.irc.factory.server, 'channels').split())) for row in consignments: + label = (' (%s)' % row.label.encode('utf-8') if row.label else '') target = row.channel or row.nick target = target.encode('utf-8') removed = False @@ -319,7 +320,6 @@ class Module: code = data[0] last = data[1] desc = data[2] - label = (' (%s)' % row.label.encode('utf-8') if row.label else '') msg = '%s: \002%s\002 %s - %s' % (row.nick.encode('utf-8'), package.code.encode('utf-8'), label, last, desc) if desc.startswith('Sendingen er utlevert'): session.delete(package) -- cgit v1.2.3