mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Validate types before asserting lengths (#56882)
This commit is contained in:
parent
6bb21c3db0
commit
9c5b72147e
1 changed files with 4 additions and 4 deletions
|
@ -25,13 +25,13 @@ def sequence_of_sequences(min=None, max=None):
|
|||
return All(
|
||||
Any(
|
||||
None,
|
||||
[Length(min=min, max=max)],
|
||||
tuple([Length(min=min, max=max)]),
|
||||
[Any(list, tuple)],
|
||||
tuple([Any(list, tuple)]),
|
||||
),
|
||||
Any(
|
||||
None,
|
||||
[Any(list, tuple)],
|
||||
tuple([Any(list, tuple)]),
|
||||
[Length(min=min, max=max)],
|
||||
tuple([Length(min=min, max=max)]),
|
||||
),
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue