Enforce separator always being in whitelist
This commit is contained in:
parent
fee4bcb24d
commit
a47777ce23
1
cli.py
1
cli.py
@ -53,7 +53,6 @@ if __name__ == '__main__':
|
|||||||
whitelist = set(args.whitelist.split())
|
whitelist = set(args.whitelist.split())
|
||||||
|
|
||||||
# modify whitelist based on arguments
|
# modify whitelist based on arguments
|
||||||
whitelist.add(args.separator)
|
|
||||||
if args.allow:
|
if args.allow:
|
||||||
whitelist = whitelist.union(set(args.allow))
|
whitelist = whitelist.union(set(args.allow))
|
||||||
if args.disallow:
|
if args.disallow:
|
||||||
|
@ -27,7 +27,7 @@ class Normalisename:
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def whitelist(self):
|
def whitelist(self):
|
||||||
return self._whitelist
|
return self._whitelist.union({self.separator})
|
||||||
|
|
||||||
def __call__(self, files):
|
def __call__(self, files):
|
||||||
for path in files:
|
for path in files:
|
||||||
|
Loading…
Reference in New Issue
Block a user