summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-08-20 17:06:05 +0200
committerChristian Poessinger <christian@poessinger.com>2021-08-21 15:26:35 +0200
commit9c97bd1b0214e102ac36eae8b2c3c9ff672a0bf3 (patch)
treed472efb82ccdef32919c8f151630e5f4980d1927
parent5141a8ca3a69108d20c8c82d1fa737f0e17ac974 (diff)
downloadvyos-1x-9c97bd1b0214e102ac36eae8b2c3c9ff672a0bf3.tar.gz
vyos-1x-9c97bd1b0214e102ac36eae8b2c3c9ff672a0bf3.zip
vyos.configdict: add note when using leaf_node_changed()
-rw-r--r--python/vyos/configdict.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/python/vyos/configdict.py b/python/vyos/configdict.py
index 0969a5353..a0056a142 100644
--- a/python/vyos/configdict.py
+++ b/python/vyos/configdict.py
@@ -108,7 +108,9 @@ def leaf_node_changed(conf, path):
"""
Check if a leaf node was altered. If it has been altered - values has been
changed, or it was added/removed, we will return a list containing the old
- value(s). If nothing has been changed, None is returned
+ value(s). If nothing has been changed, None is returned.
+
+ NOTE: path must use the real CLI node name (e.g. with a hyphen!)
"""
from vyos.configdiff import get_config_diff
D = get_config_diff(conf, key_mangling=('-', '_'))