From 92867386c77df1bd0330c8dec6cae42a9244381e Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Tue, 28 Feb 2023 18:20:13 +0000 Subject: [PATCH] helpers: fix toLuaObject ignoring empty objects (#213) --- lib/helpers.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/helpers.nix b/lib/helpers.nix index eb30b5ad..da5e1abf 100644 --- a/lib/helpers.nix +++ b/lib/helpers.nix @@ -20,7 +20,7 @@ with lib; rec { if head (stringToCharacters n) == "@" then toLuaObject v else "[${toLuaObject n}] = " + (toLuaObject v)) - (filterAttrs (n: v: !isNull v && toLuaObject v != "{}") args))) + (filterAttrs (n: v: !isNull v) args))) + "}" else if builtins.isList args then "{" + concatMapStringsSep "," toLuaObject args + "}"