about summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorLinus Heckemann <git@sphalerite.org>2023-12-14 13:56:34 +0100
committerGitHub <noreply@github.com>2023-12-14 13:56:34 +0100
commitfeed24c54bb8b08a7469432c2c6f6a275ef54975 (patch)
treeed6cc90e86c69277ef7b050e209a35f9ee7938ff /nixos/modules
parentcec423f9f9a99cec5bf615af9d44607762975f6d (diff)
parent8efe6a71cb0de07361290b7c53936478095f03b8 (diff)
Merge pull request #270704 from Avaq/avaq/vdirsync-fix-statuspath
nixos/vdirsyncer: fix config.statusPath option
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/services/networking/vdirsyncer.nix8
1 files changed, 5 insertions, 3 deletions
diff --git a/nixos/modules/services/networking/vdirsyncer.nix b/nixos/modules/services/networking/vdirsyncer.nix
index 6a069943434da..165dc70f0876a 100644
--- a/nixos/modules/services/networking/vdirsyncer.nix
+++ b/nixos/modules/services/networking/vdirsyncer.nix
@@ -20,9 +20,11 @@ let
     else
       pkgs.writeText "vdirsyncer-${name}.conf" (toIniJson (
         {
-          general = cfg'.config.general // (lib.optionalAttrs (cfg'.config.statusPath == null) {
-            status_path = "/var/lib/vdirsyncer/${name}";
-          });
+          general = cfg'.config.general // {
+            status_path = if cfg'.config.statusPath == null
+                          then "/var/lib/vdirsyncer/${name}"
+                          else cfg'.config.statusPath;
+          };
         } // (
           mapAttrs' (name: nameValuePair "pair ${name}") cfg'.config.pairs
         ) // (