1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-18 11:40:45 +00:00

nixos/printing: Fix openFirewall option

This commit is contained in:
Jonas Heinrich 2023-11-07 10:21:48 +01:00
parent a845c1b2d6
commit 31f01ff179

View file

@ -109,11 +109,10 @@ let
getGutenprint = pkgs: head (filterGutenprint pkgs); getGutenprint = pkgs: head (filterGutenprint pkgs);
parsePorts = addresses: let parsePorts = addresses: let
splitAddress = addr: lib.strings.splitString ":" addr; splitAddress = addr: strings.splitString ":" addr;
extractPort = addr: builtins.elemAt (builtins.tail (splitAddress addr)) 0; extractPort = addr: builtins.foldl' (a: b: b) "" (splitAddress addr);
toInt = str: lib.strings.toInt str;
in in
builtins.map (address: toInt (extractPort address)) addresses; builtins.map (address: strings.toInt (extractPort address)) addresses;
in in