From 9aa41f8a0a4ae09aa39abd6dc3b6d2e00f8a8c2d Mon Sep 17 00:00:00 2001 From: pjrm Date: Fri, 27 Feb 2009 02:15:41 +0000 Subject: [PATCH] share/extensions/inkex.py: Fix a couple of issues reported by pychecker. --- share/extensions/inkex.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/share/extensions/inkex.py b/share/extensions/inkex.py index 98ebf9d1f..adc0d0fed 100755 --- a/share/extensions/inkex.py +++ b/share/extensions/inkex.py @@ -90,7 +90,7 @@ def check_inkbool(option, opt, value): elif str(value).capitalize() == 'False': return False else: - raise OptionValueError("option %s: invalid inkbool value: %s" % (opt, value)) + raise optparse.OptionValueError("option %s: invalid inkbool value: %s" % (opt, value)) def addNS(tag, ns=None): val = tag @@ -161,10 +161,10 @@ class Effect: def getselected(self): """Collect selected nodes""" - for id in self.options.ids: - path = '//*[@id="%s"]' % id + for i in self.options.ids: + path = '//*[@id="%s"]' % i for node in self.document.xpath(path, namespaces=NSS): - self.selected[id] = node + self.selected[i] = node def getdocids(self): docIdNodes = self.document.xpath('//@id', namespaces=NSS) -- 2.30.2