aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2022-02-11 15:50:12 +0100
committerEelco Dolstra <edolstra@gmail.com>2022-02-11 15:50:12 +0100
commitcdc90c2776ee5542fd4d4e1aaa06d1d826daecb0 (patch)
tree25b2764bfe3112549b8e74e5b81e27fb71fb3868
parentd2f9a081b81ae0c4ef194fc66b94a31fb8ed6d73 (diff)
parseInstallables(): Don't try the flake attr path prefixes when no fragment is specified
Fixes #5880.
-rw-r--r--src/libcmd/installables.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcmd/installables.cc b/src/libcmd/installables.cc
index 5e8b62e1a..9f138b420 100644
--- a/src/libcmd/installables.cc
+++ b/src/libcmd/installables.cc
@@ -709,7 +709,7 @@ std::vector<std::shared_ptr<Installable>> SourceExprCommand::parseInstallables(
getEvalState(),
std::move(flakeRef),
fragment == "" ? getDefaultFlakeAttrPaths() : Strings{fragment},
- getDefaultFlakeAttrPathPrefixes(),
+ fragment == "" ? Strings{} : getDefaultFlakeAttrPathPrefixes(),
lockFlags));
continue;
} catch (...) {