diff options
author | Christian Breunig <christian@breunig.cc> | 2024-03-21 05:30:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-21 05:30:24 +0100 |
commit | b09a67b4617efd8f60da0db6e56a7357254c5bd4 (patch) | |
tree | fd5a586e461537115b4735dddf78946bd536a9fa | |
parent | d03916b59d69c765ecba1f727d8dd1d5a952ccbc (diff) | |
parent | 72378c67ef1eee01a06e2f9a194a0870c6a7fdd2 (diff) | |
download | vyos-1x-b09a67b4617efd8f60da0db6e56a7357254c5bd4.tar.gz vyos-1x-b09a67b4617efd8f60da0db6e56a7357254c5bd4.zip |
Merge pull request #3153 from aapostoliuk/T6130-circinus
policy: T6130: Revert commit 960cace
-rwxr-xr-x | src/migration-scripts/policy/3-to-4 | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/migration-scripts/policy/3-to-4 b/src/migration-scripts/policy/3-to-4 index 1ebb248b0..476fa3af2 100755 --- a/src/migration-scripts/policy/3-to-4 +++ b/src/migration-scripts/policy/3-to-4 @@ -51,7 +51,7 @@ def community_migrate(config: ConfigTree, rule: list[str]) -> bool: :rtype: bool """ community_list = list((config.return_value(rule)).split(" ")) - + config.delete(rule) if 'none' in community_list: config.set(rule + ['none']) return False @@ -61,10 +61,8 @@ def community_migrate(config: ConfigTree, rule: list[str]) -> bool: community_action = 'add' community_list.remove('additive') for community in community_list: - if len(community): - config.set(rule + [community_action], value=community, - replace=False) - config.delete(rule) + config.set(rule + [community_action], value=community, + replace=False) if community_action == 'replace': return False else: |