# HG changeset patch # User hodgestar # Date 1359200315 0 # Node ID 2d9346a9935269eab1f650be9ee31fc5079ee1fc # Parent 480cf1be291aadeab04dc39395460b4a8fd46ac9 Remove unused isinstance checks. diff --git a/genshi/input.py b/genshi/input.py --- a/genshi/input.py +++ b/genshi/input.py @@ -366,9 +366,7 @@ fixed_attrib = [] for name, value in attrib: # Fixup minimized attributes if value is None: - value = unicode(name) - elif not isinstance(value, unicode): - value = value.decode(self.encoding, 'replace') + value = name fixed_attrib.append((QName(name), stripentities(value))) self._enqueue(START, (QName(tag), Attrs(fixed_attrib))) @@ -386,8 +384,6 @@ break def handle_data(self, text): - if not isinstance(text, unicode): - text = text.decode(self.encoding, 'replace') self._enqueue(TEXT, text) def handle_charref(self, name):