diff options
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/monitoring/graphite.nix | 2 | ||||
-rw-r--r-- | nixos/modules/services/monitoring/prometheus/default.nix | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/nixos/modules/services/monitoring/graphite.nix b/nixos/modules/services/monitoring/graphite.nix index c5352e5887da..98931e65bb56 100644 --- a/nixos/modules/services/monitoring/graphite.nix +++ b/nixos/modules/services/monitoring/graphite.nix @@ -4,7 +4,7 @@ with lib; let cfg = config.services.graphite; - writeTextOrNull = f: t: if t == null then null else pkgs.writeTextDir f t; + writeTextOrNull = f: t: mapNullable (pkgs.writeTextDir f) t; dataDir = cfg.dataDir; diff --git a/nixos/modules/services/monitoring/prometheus/default.nix b/nixos/modules/services/monitoring/prometheus/default.nix index cf9deccbffe2..5c4a48a7db4b 100644 --- a/nixos/modules/services/monitoring/prometheus/default.nix +++ b/nixos/modules/services/monitoring/prometheus/default.nix @@ -134,7 +134,7 @@ let }; }); default = null; - apply = x: if x == null then null else _filter x; + apply = x: mapNullable _filter x; description = '' Optional http login credentials for metrics scraping. ''; |