From 90a8ea505169f606ca543f40838c2f1f09b23352 Mon Sep 17 00:00:00 2001 From: Wen Liang Date: Thu, 6 Oct 2022 14:47:25 -0400 Subject: [PATCH] bond: improve the validation for setting peer_notif_delay Synchronize with NM, the default value of peer_notif_delay in NM is 0, which is not considered as enabling the setting or specifying the delay. Signed-off-by: Wen Liang --- module_utils/network_lsr/argument_validator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module_utils/network_lsr/argument_validator.py b/module_utils/network_lsr/argument_validator.py index e297168..98261d1 100644 --- a/module_utils/network_lsr/argument_validator.py +++ b/module_utils/network_lsr/argument_validator.py @@ -1494,7 +1494,7 @@ class ArgValidator_DictBond(ArgValidatorDict): name, "the bond option downdelay or updelay is only valid with miimon enabled", ) - if result["peer_notif_delay"] is not None: + if result["peer_notif_delay"]: if not result["miimon"] or result["peer_notif_delay"] % result["miimon"]: raise ValidationError( name,