def http_request(self, request):
        if not self.used:
            if self.password_mgr.api_token:
                request.add_header(self.AUTH_HEADER,
                                   self.password_mgr.api_token % 'token %s')
                self.used = True
            elif self.password_mgr.rb_user:
                # Note that we call password_mgr.find_user_password to get the
                # username and password we're working with.
                username, password = \
                    self.password_mgr.find_user_password('Web API', self.url)
                raw = '%s:%s' % (username, password)
                request.add_header(self.AUTH_HEADER,
                                   'Basic %s' % base64.b64encode(raw).strip())
                self.used = True

        return request
dataset/ETHPy150Open reviewboard/rbtools/rbtools/api/request.py/PresetHTTPAuthHandler.http_request/swapped operands of `%`