lib/gvariant: Fix error message for unsupported primitives

Without this, passing an integer to a setting will fail with a confusing error:

    error: cannot coerce an integer to a string
This commit is contained in:
Jan Tojnar
2024-05-02 23:19:08 +02:00
parent 5b2b3b8558
commit 96e6f1a418
+1 -1
View File
@@ -71,7 +71,7 @@ rec {
else if isGVariant v then
v
else
throw "The GVariant type of ${v} can't be inferred.";
throw "The GVariant type of ${builtins.typeOf v} can't be inferred.";
/* Returns the GVariant array from the given type of the elements and a Nix list.