gpsd: use optionalString

Changed files
+2 -2
nixos
modules
services
misc
+2 -2
nixos/modules/services/misc/gpsd.nix
···
ExecStart = ''
${pkgs.gpsd}/sbin/gpsd -D "${toString cfg.debugLevel}" \
-S "${toString cfg.port}" \
-
${if cfg.readonly then "-b" else ""} \
-
${if cfg.nowait then "-n" else ""} \
+
${optionalString cfg.readonly "-b"} \
+
${optionalString cfg.nowait "-n"} \
"${cfg.device}"
'';
};