From df3ad4c0646493553b68f59fc017b56df6cbc328 Mon Sep 17 00:00:00 2001 From: Plamen Dimitrov Date: Thu, 12 May 2022 08:03:11 +0300 Subject: [PATCH] Drop any None and thus previously required default values There can be no "None" cnfvar values as these will be automatically converted to "None" strings. Empty strings are thus their correct equivalent after the cnfline classes migration. As no child cnfvars could be considered obligatory and whether they are required depends entirely on choices for other child cnfvars, we will not try to implement any option for an early fail and simply delegate any further validation to the production code. --- src/cnfvar/templates.py | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cnfvar/templates.py b/src/cnfvar/templates.py index a0b2e89..9c39520 100644 --- a/src/cnfvar/templates.py +++ b/src/cnfvar/templates.py @@ -86,8 +86,8 @@ intraclient_defaults = { "INTRACLIENT_DNS_RELAYING_ALLOWED": "1", "INTRACLIENT_EMAIL_RELAYING_ALLOWED": "1", "INTRACLIENT_FIREWALL_RULESET_REF": "5", - "INTRACLIENT_IP": None, - "INTRACLIENT_MAC": None, + "INTRACLIENT_IP": "", + "INTRACLIENT_MAC": "", "INTRACLIENT_PROXY_PROFILE_REF": "-1", } #: UI defaults for a NIC instance @@ -188,7 +188,7 @@ vpnconn_defaults = { "VPNCONN_LIFETIME_IPSECSA": "60", "VPNCONN_OFFLINE_DETECTION_SEC": "60", "VPNCONN_PEER_DNS": "", - "VPNCONN_PEER_IP": None, + "VPNCONN_PEER_IP": "", "VPNCONN_PEER_TYPE": "IP", "VPNCONN_PROXY_PROFILE_REF": "-2", "VPNCONN_PSK": "", -- 1.7.1