dconf: assume empty list value is a list of strings

Fixes #769.

(cherry picked from commit caf3349f01)
This commit is contained in:
Olli Helenius 2019-07-28 13:01:29 +03:00 committed by Robert Helgesson
parent a85f22164d
commit 5d054abe6a
No known key found for this signature in database
GPG key ID: 36BDAA14C2797E89

View file

@ -13,9 +13,15 @@ let
let
tweakVal = v:
if isString v then "'${v}'"
else if isList v then "[" + concatMapStringsSep "," tweakVal v + "]"
else if isList v then tweakList v
else if isBool v then (if v then "true" else "false")
else toString v;
# Assume empty list is a list of strings, see #769
tweakList = v:
if v == [] then "@as []"
else "[" + concatMapStringsSep "," tweakVal v + "]";
in
"${key}=${tweakVal value}";