mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-27 02:24:18 +00:00
adding __str__ to make export to har nicer
This commit is contained in:
parent
53792a5a28
commit
35f36481b9
@ -812,6 +812,11 @@ class ClientConnect(controller.Msg):
|
||||
def __eq__(self, other):
|
||||
return self._get_state() == other._get_state()
|
||||
|
||||
def __str__(self):
|
||||
if self.address:
|
||||
return "%s:%d"%(self.address[0],self.address[1])
|
||||
return "None"
|
||||
|
||||
def _load_state(self, state):
|
||||
self.close = True
|
||||
self.error = state["error"]
|
||||
|
Loading…
Reference in New Issue
Block a user