I want to remove empty values and duplicates from an array, duplicate values are getting removed, empty isn't
template:
local sub = [ "", "one", "two", "two", ""];
{
env: std.prune(std.uniq(std.sort(sub)))
}
output:
{
"env": [
"",
"one",
"two"
]
}
std.prune is supposed to remove empty, null but it is not happening, am I doing something wrong? or is there other way to remove empty values?