allowInsecureDefaultPredicate: fix to use getName

this allows correct operation with packages only having pname and version
specified, resolving issue #73737
This commit is contained in:
Robert Scott 2019-12-15 17:59:43 +00:00
parent 5425557214
commit e1e3df423a

View file

@ -67,7 +67,7 @@ let
isUnfree (lib.lists.toList attrs.meta.license) &&
!allowUnfreePredicate attrs;
allowInsecureDefaultPredicate = x: builtins.elem x.name (config.permittedInsecurePackages or []);
allowInsecureDefaultPredicate = x: builtins.elem (getName x) (config.permittedInsecurePackages or []);
allowInsecurePredicate = x: (config.allowInsecurePredicate or allowInsecureDefaultPredicate) x;
hasAllowedInsecure = attrs: