mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-24 03:33:11 +01:00
We should assert after we call the callable.
This commit is contained in:
parent
6061f49a48
commit
f2a34f78c8
@ -108,9 +108,9 @@ def invertCapability(capability):
|
|||||||
return makeAntiCapability(capability)
|
return makeAntiCapability(capability)
|
||||||
|
|
||||||
def canonicalCapability(capability):
|
def canonicalCapability(capability):
|
||||||
assert isCapability(capability), 'got %s' % capability
|
|
||||||
if callable(capability):
|
if callable(capability):
|
||||||
capability = capability()
|
capability = capability()
|
||||||
|
assert isCapability(capability), 'got %s' % capability
|
||||||
return capability.lower()
|
return capability.lower()
|
||||||
|
|
||||||
def unWildcardHostmask(hostmask):
|
def unWildcardHostmask(hostmask):
|
||||||
|
Loading…
Reference in New Issue
Block a user