Commit dcbc78c
authored
fix(docs): update example result, when using null_override = false (#33)
This pull request updates documentation examples to accurately reflect
the behavior of the `deep_merge` function when merging values with
`null` and `null_override = false`.
Documentation corrections:
* Updated the example result in `docs/functions/deep_merge.md` to show
that `optional_setting` retains its original value ("enabled") when
overridden with `null` and `null_override = false`.
* Made the same correction in `internal/provider/deep_merge_function.md`
for consistency and accuracy.
* Changes have been also tested
```
> provider::lara-utils::deep_merge([{ name = "service", port = 8080, optional_setting = "enabled" }, { port = 9090, optional_setting = null }], { null_override = true })
{
"name" = "service"
"optional_setting" = null
"port" = 9090
}
> provider::lara-utils::deep_merge([{ name = "service", port = 8080, optional_setting = "enabled" }, { port = 9090, optional_setting = null }], { null_override = false })
{
"name" = "service"
"optional_setting" = "enabled"
"port" = 9090
}
```1 parent 3e5fcc7 commit dcbc78c
2 files changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
0 commit comments