summary refs log tree commit diff
path: root/lib/strings.nix
diff options
context:
space:
mode:
authorMalte Brandy <malte.brandy@maralorn.de>2021-05-07 15:03:54 +0200
committerMalte Brandy <malte.brandy@maralorn.de>2021-05-07 15:03:54 +0200
commit2a11f1f5cc1c4680b49240203db18ecbb19b9cc5 (patch)
treedf44c5fcd797c97297ab663b63167e9b4bc06a72 /lib/strings.nix
parentf73c2278d07e674233040422b71d965a0587756f (diff)
parentae1c8ede09b53007ba9b3c32f926c9c03547ae8b (diff)
downloadnixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar.gz
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar.bz2
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar.lz
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar.xz
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.tar.zst
nixpkgs-2a11f1f5cc1c4680b49240203db18ecbb19b9cc5.zip
Merge branch 'master' into haskell-updates
Diffstat (limited to 'lib/strings.nix')
-rw-r--r--lib/strings.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/strings.nix b/lib/strings.nix
index 2e502588bf8..49fa0196a0b 100644
--- a/lib/strings.nix
+++ b/lib/strings.nix
@@ -659,7 +659,7 @@ rec {
      Example:
        isStorePath "/nix/store/d945ibfx9x185xf04b890y4f9g3cbb63-python-2.7.11/bin/python"
        => false
-       isStorePath "/nix/store/d945ibfx9x185xf04b890y4f9g3cbb63-python-2.7.11/"
+       isStorePath "/nix/store/d945ibfx9x185xf04b890y4f9g3cbb63-python-2.7.11"
        => true
        isStorePath pkgs.python
        => true
@@ -667,7 +667,7 @@ rec {
        => false
   */
   isStorePath = x:
-    if isCoercibleToString x then
+    if !(isList x) && isCoercibleToString x then
       let str = toString x; in
       substring 0 1 str == "/"
       && dirOf str == storeDir