mirror of https://github.com/n1nj4sec/pupy.git
Add ability to unset keys from randoms section
This commit is contained in:
parent
b7515c6a74
commit
8e285ea8a0
|
@ -77,6 +77,15 @@ class PupyConfig(ConfigParser):
|
||||||
else:
|
else:
|
||||||
return path.abspath(retfolder)
|
return path.abspath(retfolder)
|
||||||
|
|
||||||
|
def remove_option(self, section, key):
|
||||||
|
if section != 'randoms':
|
||||||
|
ConfigParser.unset(self, section, key)
|
||||||
|
else:
|
||||||
|
if key in self.randoms:
|
||||||
|
del self.randoms[key]
|
||||||
|
elif key == 'all':
|
||||||
|
self.randoms = {}
|
||||||
|
|
||||||
def set(self, section, key, value, **kwargs):
|
def set(self, section, key, value, **kwargs):
|
||||||
if section != 'randoms':
|
if section != 'randoms':
|
||||||
ConfigParser.set(self, section, key, value)
|
ConfigParser.set(self, section, key, value)
|
||||||
|
|
Loading…
Reference in New Issue