From c039e4a2e322ee4e0a173f164be598dc630d3579 Mon Sep 17 00:00:00 2001 From: Maximilian Hils Date: Wed, 25 Jun 2014 23:25:49 +0200 Subject: [PATCH] fix ProxyError inheritance --- libmproxy/proxy/primitives.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/libmproxy/proxy/primitives.py b/libmproxy/proxy/primitives.py index 691db9222..6154749cd 100644 --- a/libmproxy/proxy/primitives.py +++ b/libmproxy/proxy/primitives.py @@ -1,12 +1,10 @@ from __future__ import absolute_import + class ProxyError(Exception): - def __init__(self, code, msg, headers=None): - self.code, self.msg, self.headers = code, msg, headers - - def __str__(self): - return "ProxyError(%s, %s)" % (self.code, self.msg) - + def __init__(self, code, message, headers=None): + super(ProxyError, self).__init__(self, message) + self.code, self.headers = code, headers class ConnectionTypeChange(Exception): """