diff options
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/web-apps/mastodon.nix | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/nixos/modules/services/web-apps/mastodon.nix b/nixos/modules/services/web-apps/mastodon.nix index cf5329be489c1..247eb707b15c6 100644 --- a/nixos/modules/services/web-apps/mastodon.nix +++ b/nixos/modules/services/web-apps/mastodon.nix @@ -588,11 +588,12 @@ in { ''; } { - assertion = 1 == builtins.length - (lib.mapAttrsToList - (_: v: builtins.elem "scheduler" v.jobClasses || v.jobClasses == [ ]) - cfg.sidekiqProcesses); - message = "There must be one and only one Sidekiq queue in services.mastodon.sidekiqProcesses with jobClass \"scheduler\"."; + assertion = 1 == + (lib.count (x: x) + (lib.mapAttrsToList + (_: v: builtins.elem "scheduler" v.jobClasses || v.jobClasses == [ ]) + cfg.sidekiqProcesses)); + message = "There must be exactly one Sidekiq queue in services.mastodon.sidekiqProcesses with jobClass \"scheduler\"."; } ]; |