mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-27 02:24:18 +00:00
Raise AttributeError from Options.__getattr__
This commit is contained in:
parent
c9a0fe6a0e
commit
077850bd10
@ -42,7 +42,10 @@ class Options(object):
|
||||
return self.__class__(**self._opts)
|
||||
|
||||
def __getattr__(self, attr):
|
||||
return self._opts[attr]
|
||||
if attr in self._opts:
|
||||
return self._opts[attr]
|
||||
else:
|
||||
raise AttributeError()
|
||||
|
||||
def __setattr__(self, attr, value):
|
||||
if attr not in self._opts:
|
||||
|
Loading…
Reference in New Issue
Block a user