git.iko.soy/typeable/nixpkgs
on master help sign in
lib.isDerivation: Simplify
commit3ddac7a41a3b755e2317a3e9ba2b2e61b57b9fb3 authorRobert Hensing <robert@roberthensing.nl> dateWed 9 Mar 2022, 15:48 (5 years ago) parent74be820
1 file changed+1−1
lib/attrsets.nix+1−1
lib/attrsets.nix+1−1
@@ -327,7 +327,7 @@ rec {
327327 isDerivation "foobar"
328328 => false
329329 */
330− isDerivation = x: isAttrs x && x ? type && x.type == "derivation";
330+ isDerivation = x: x.type or null == "derivation";
331331
332332 /* Converts a store path to a fake derivation. */
333333 toDerivation = path: