diff options
author | Matthew Bauer <mjbauer95@gmail.com> | 2020-06-19 14:22:06 -0400 |
---|---|---|
committer | Matthew Bauer <mjbauer95@gmail.com> | 2020-06-19 14:22:06 -0400 |
commit | 2796b01e863bf3a6d28cc89bb46c6388d8b73fbc (patch) | |
tree | 20fec553f605b3a6f7474cd337eb457c9a8a56f1 /src/nix/show-derivation.cc | |
parent | 5e631e3304aaf00b912c12025debfd35942a0ca9 (diff) | |
parent | 424bb5819f736af7413c343d462663474222eaac (diff) |
Merge remote-tracking branch 'origin/master' into substitute-other-storedir
Diffstat (limited to 'src/nix/show-derivation.cc')
-rw-r--r-- | src/nix/show-derivation.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nix/show-derivation.cc b/src/nix/show-derivation.cc index 2d31894c2..5d77cfdca 100644 --- a/src/nix/show-derivation.cc +++ b/src/nix/show-derivation.cc @@ -70,9 +70,9 @@ struct CmdShowDerivation : InstallablesCommand for (auto & output : drv.outputs) { auto outputObj(outputsObj.object(output.first)); outputObj.attr("path", store->printStorePath(output.second.path)); - if (output.second.hash != "") { - outputObj.attr("hashAlgo", output.second.hashAlgo); - outputObj.attr("hash", output.second.hash); + if (output.second.hash) { + outputObj.attr("hashAlgo", output.second.hash->printMethodAlgo()); + outputObj.attr("hash", output.second.hash->hash.to_string(Base16, false)); } } } |