diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2015-04-14 11:58:10 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2015-04-14 11:58:10 +1200 |
commit | bea0bd236a60e3e6c80027448e51b7802394304a (patch) | |
tree | 1cc160e19eb1834703798503f1818e4278bce1b2 /libmproxy/console/flowview.py | |
parent | f37efecd0a22313eacad33251512ef371557fde7 (diff) | |
download | mitmproxy-bea0bd236a60e3e6c80027448e51b7802394304a.tar.gz mitmproxy-bea0bd236a60e3e6c80027448e51b7802394304a.tar.bz2 mitmproxy-bea0bd236a60e3e6c80027448e51b7802394304a.zip |
Housekeeping and cleanups
- No output to stdout on load in examples - they muck up the test suite.
- Use the odict module directly, rather than aliasing it. The small convenience
this gives to scripters is not worth it.
- Move the cookie tests from the flow test module to the protocol_http test
module.
Diffstat (limited to 'libmproxy/console/flowview.py')
-rw-r--r-- | libmproxy/console/flowview.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/libmproxy/console/flowview.py b/libmproxy/console/flowview.py index 9776f2b1..d7dc0d23 100644 --- a/libmproxy/console/flowview.py +++ b/libmproxy/console/flowview.py @@ -1,6 +1,7 @@ from __future__ import absolute_import import os, sys, copy import urwid +from netlib import odict from . import common, grideditor, contentview, signals, searchable, tabs from . import flowdetailview from .. import utils, flow, controller @@ -275,11 +276,11 @@ class FlowView(tabs.Tabs): signals.flow_change.send(self, flow = self.flow) def set_headers(self, lst, conn): - conn.headers = flow.ODictCaseless(lst) + conn.headers = odict.ODictCaseless(lst) signals.flow_change.send(self, flow = self.flow) def set_query(self, lst, conn): - conn.set_query(flow.ODict(lst)) + conn.set_query(odict.ODict(lst)) signals.flow_change.send(self, flow = self.flow) def set_path_components(self, lst, conn): @@ -287,7 +288,7 @@ class FlowView(tabs.Tabs): signals.flow_change.send(self, flow = self.flow) def set_form(self, lst, conn): - conn.set_form_urlencoded(flow.ODict(lst)) + conn.set_form_urlencoded(odict.ODict(lst)) signals.flow_change.send(self, flow = self.flow) def edit_form(self, conn): @@ -311,7 +312,7 @@ class FlowView(tabs.Tabs): if not self.flow.response: self.flow.response = HTTPResponse( self.flow.request.httpversion, - 200, "OK", flow.ODictCaseless(), "" + 200, "OK", odict.ODictCaseless(), "" ) self.flow.response.reply = controller.DummyReply() message = self.flow.response |