Apply suggestions from code review

Co-authored-by: Laurent Indermühle <laurent.indermuehle@pm.me>
This commit is contained in:
tompal3 2024-01-09 08:46:59 +02:00 committed by GitHub
parent 379b25e8fa
commit 682fae4125
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 21 additions and 40 deletions

View file

@ -481,9 +481,8 @@ def main():
module.fail_json(msg="password_expire value interval \
should be used with password_expire_interval")
if password_expire_interval:
if password_expire_interval < 1:
module.fail_json(msg="password_expire_interval value \
if password_expire_interval and password_expire_interval < 1:
module.fail_json(msg="password_expire_interval value \
should be positive number")
cursor = None