diff options
author | Felix Buehler <account@buehler.rocks> | 2023-06-24 20:19:19 +0200 |
---|---|---|
committer | Felix Buehler <account@buehler.rocks> | 2023-06-24 20:19:19 +0200 |
commit | f3719756b550113c1acbbab00c89a56fb77256f2 (patch) | |
tree | a94f6678f9b1b25c6773bdd7a35422aabc816032 /pkgs/build-support/kernel | |
parent | e9e3f2e7362aba3ef709173d1777f0b893fc0ebf (diff) |
treewide: use optionalString instead of 'then ""'
Diffstat (limited to 'pkgs/build-support/kernel')
-rw-r--r-- | pkgs/build-support/kernel/make-initrd-ng.nix | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/build-support/kernel/make-initrd-ng.nix b/pkgs/build-support/kernel/make-initrd-ng.nix index f3cf3d59f92b0..2418838176ef3 100644 --- a/pkgs/build-support/kernel/make-initrd-ng.nix +++ b/pkgs/build-support/kernel/make-initrd-ng.nix @@ -72,7 +72,7 @@ in ${if makeUInitrd then "uInitrdCompression" else null} = uInitrdCompression; passAsFile = ["contents"]; - contents = lib.concatMapStringsSep "\n" ({ object, symlink, ... }: "${object}\n${if symlink == null then "" else symlink}") contents + "\n"; + contents = lib.concatMapStringsSep "\n" ({ object, symlink, ... }: "${object}\n${lib.optionalString (symlink != null) symlink}") contents + "\n"; nativeBuildInputs = [makeInitrdNGTool cpio] ++ lib.optional makeUInitrd ubootTools ++ lib.optional strip binutils; |