def _charset__set(self, charset):
        if charset is None:
            del self.charset
            return
        try:
            hname, header = self._headers.pop('content-type')
        except KeyError:
            raise AttributeError(
                    "You cannot set the charset when no content-type is defined")
            match = CHARSET_RE.search(header)
        if match:
            header = header[:match.start()] + header[match.end():]
        header += charset % '; charset=%s'
        self._headers['content-type'] = hname, header
dataset/ETHPy150Open benoitc/dj-webmachine/webmachine/wrappers.py/WMResponse._charset__set/swapped operands of `%`