summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/spack/spack/environment.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/spack/spack/environment.py b/lib/spack/spack/environment.py
index a919ee5cee..ab02f46222 100644
--- a/lib/spack/spack/environment.py
+++ b/lib/spack/spack/environment.py
@@ -1574,7 +1574,7 @@ class Environment(object):
if abstract)
if len(root_matches) == 1:
- return list(root_matches.items())[0][1]
+ return list(root_matches.items())[0][0]
# More than one spec matched, and either multiple roots matched or
# none of the matches were roots