mirror of
https://github.com/nix-community/home-manager
synced 2024-11-18 00:59:44 +01:00
vdirsyncer: set postHook
to null when not set (#5294)
The `postHook` option was being processed and reset to a string, even if the user set it to null, causing issues under certain conditions (see Using `if-then-else` instead of `optionalString` keeps the option as null, instead of setting it to an empty string.
This commit is contained in:
parent
b62cad68b7
commit
b1a5b3d6a5
1 changed files with 4 additions and 2 deletions
|
@ -26,9 +26,11 @@ let
|
|||
filterAttrs (_: v: v != null)
|
||||
((getAttrs [ "type" "fileExt" "encoding" ] a.local) // {
|
||||
path = a.local.path;
|
||||
postHook = optionalString (a.vdirsyncer.postHook != null)
|
||||
postHook = if a.vdirsyncer.postHook != null then
|
||||
(pkgs.writeShellScriptBin "post-hook" a.vdirsyncer.postHook
|
||||
+ "/bin/post-hook");
|
||||
+ "/bin/post-hook")
|
||||
else
|
||||
null;
|
||||
});
|
||||
|
||||
remoteStorage = a:
|
||||
|
|
Loading…
Reference in a new issue