Fix require_only_one. (#83511)

pull/82995/merge
Felix Fontein 5 months ago committed by GitHub
parent 00ddc27d69
commit 7d678cbd96
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -89,7 +89,7 @@ def require_only_one(keys):
found = None
for k in obj.keys():
if k in keys:
if k is None:
if found is None:
found = k
else:
raise Invalid('Found conflicting keys, must contain only one of {}'.format(keys))

Loading…
Cancel
Save