summary refs log tree commit diff
path: root/pkgs/build-support/dotnet
diff options
context:
space:
mode:
authorFelix Buehler <account@buehler.rocks>2023-02-14 19:11:59 +0100
committerFelix Buehler <account@buehler.rocks>2023-02-14 19:11:59 +0100
commitbc3d5934d7f276a21537b40159491257ee163d94 (patch)
tree53b1d9bd9cb148a0ab34f2fd9e1d94802dde639e /pkgs/build-support/dotnet
parent3bee4ab8db244db328b41ae5f4fbce19b658f1be (diff)
downloadnixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar.gz
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar.bz2
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar.lz
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar.xz
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.tar.zst
nixpkgs-bc3d5934d7f276a21537b40159491257ee163d94.zip
treewide: use lib.optionals
Diffstat (limited to 'pkgs/build-support/dotnet')
-rw-r--r--pkgs/build-support/dotnet/make-nuget-source/default.nix4
1 files changed, 1 insertions, 3 deletions
diff --git a/pkgs/build-support/dotnet/make-nuget-source/default.nix b/pkgs/build-support/dotnet/make-nuget-source/default.nix
index 8dc77f3aac0..ea1c5328082 100644
--- a/pkgs/build-support/dotnet/make-nuget-source/default.nix
+++ b/pkgs/build-support/dotnet/make-nuget-source/default.nix
@@ -30,9 +30,7 @@ let
     meta.licence = let
       depLicenses = lib.splitString "\n" (builtins.readFile "${nuget-source}/share/licenses");
     in (lib.flatten (lib.forEach depLicenses (spdx:
-      if (spdx != "")
-        then lib.getLicenseFromSpdxId spdx
-        else []
+      lib.optionals (spdx != "") (lib.getLicenseFromSpdxId spdx)
     )));
   };
 in nuget-source