diff options
| author | John Estabrook <jestabro@vyos.io> | 2025-08-13 15:29:37 -0500 |
|---|---|---|
| committer | John Estabrook <jestabro@vyos.io> | 2025-08-13 18:21:09 -0500 |
| commit | c652a90ef4a5b4a78b48a390e59370b73b591f50 (patch) | |
| tree | 70c091e37ea90e8bc42e9a812a086804a20fb777 /src | |
| parent | 5275acdb005dfb2fb842b340f56c815133fa7fe8 (diff) | |
| download | vyconf-c652a90ef4a5b4a78b48a390e59370b73b591f50.tar.gz vyconf-c652a90ef4a5b4a78b48a390e59370b73b591f50.zip | |
T7718: move prune_del_path to Vyos1x.Config_tree
Diffstat (limited to 'src')
| -rw-r--r-- | src/session.ml | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/src/session.ml b/src/session.ml index 375ec43..31bd411 100644 --- a/src/session.ml +++ b/src/session.ml @@ -101,22 +101,13 @@ let set w s path = in {s with proposed_config=config; changeset=(op :: s.changeset)} -let prune_del_path node path = - if CT.is_tag_value node path then - let tag_path = Vyos1x.Util.drop_last path in - let terminal = VT.is_terminal_path node tag_path in - match terminal with - | true -> CT.delete node tag_path None - | false -> node - else node - let delete w s path = let path, value = split_path w s path in let op = CfgDelete (path, value) in let config = try apply_cfg_op op s.proposed_config |> - (fun c -> prune_del_path c path) + (fun c -> CT.prune_delete c path) with | VT.Nonexistent_path | CT.No_such_value -> s.proposed_config in |
