mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-02-04 07:51:50 +00:00
fix ruff case SIM110 (#11215)
* fix ruff case SIM110 * Update plugins/module_utils/xenserver.py Co-authored-by: Felix Fontein <felix@fontein.de> * add changelog frag --------- Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
parent
d364e35423
commit
862fe79a22
16 changed files with 34 additions and 72 deletions
|
|
@ -159,11 +159,7 @@ def is_input_dangerous(string):
|
|||
if not string:
|
||||
return False
|
||||
|
||||
for pattern in (PATTERN_1, PATTERN_2, PATTERN_3):
|
||||
if re.search(pattern, string):
|
||||
return True
|
||||
|
||||
return False
|
||||
return any(pattern.search(string) for pattern in (PATTERN_1, PATTERN_2, PATTERN_3))
|
||||
|
||||
|
||||
def check_input(module, *args):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue