From 2e3b722305ab6ff06a87a77a1be5698e622dda3e Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Sat, 5 Dec 2015 05:02:24 -0600 Subject: [PATCH] Tweak. --- tasks/infobox_station.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasks/infobox_station.py b/tasks/infobox_station.py index 791a81d..29cb789 100644 --- a/tasks/infobox_station.py +++ b/tasks/infobox_station.py @@ -117,7 +117,7 @@ class InfoboxStation(Task): code.replace(prev, prev[:-1]) code.insert_before(tmpl, cats + "\n\n") - def _get_transclusions(self, title): + def _get_transclusions(self, tmpl): """ Return a list of mainspace translusions of the given template. """ @@ -127,5 +127,5 @@ class InfoboxStation(Task): WHERE tl_namespace = ? AND tl_title = ? AND tl_from_namespace = ?""" results = self.site.sql_query(query, ( - constants.NS_TEMPLATE, title.replace(" ", "_"), constants.NS_MAIN)) - return [title.replace("_", " ") for (title,) in results] + constants.NS_TEMPLATE, tmpl.replace(" ", "_"), constants.NS_MAIN)) + return [title.decode("utf8").replace("_", " ") for (title,) in results]