diff options
author | Maximilian Hils <git@maximilianhils.com> | 2019-11-19 18:29:22 +0100 |
---|---|---|
committer | Maximilian Hils <git@maximilianhils.com> | 2019-11-19 18:29:22 +0100 |
commit | c7eedcbc1a90e9705172ffd6333cb740a5e9883f (patch) | |
tree | 4f538231e068ef40f93b7277254d138d0a33b0e8 /mitmproxy/addons | |
parent | 76e648410745c61f7a659e864230b6154dc43ced (diff) | |
download | mitmproxy-c7eedcbc1a90e9705172ffd6333cb740a5e9883f.tar.gz mitmproxy-c7eedcbc1a90e9705172ffd6333cb740a5e9883f.tar.bz2 mitmproxy-c7eedcbc1a90e9705172ffd6333cb740a5e9883f.zip |
fix 'set' to only accept a single argument
Diffstat (limited to 'mitmproxy/addons')
-rw-r--r-- | mitmproxy/addons/core.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mitmproxy/addons/core.py b/mitmproxy/addons/core.py index 6fb2bf1e..8a3acedb 100644 --- a/mitmproxy/addons/core.py +++ b/mitmproxy/addons/core.py @@ -83,14 +83,14 @@ class Core: ) @command.command("set") - def set(self, option: str, *value: str) -> None: + def set(self, option: str, value: str = "") -> None: """ Set an option. When the value is omitted, booleans are set to true, strings and integers are set to None (if permitted), and sequences are emptied. Boolean values can be true, false or toggle. Multiple values are concatenated with a single space. """ - strspec = f"{option}={' '.join(value)}" + strspec = f"{option}={value}" try: ctx.options.set(strspec) except exceptions.OptionsError as e: |