From 59d0de6ea17b7836e7f2e169ea4c8e65b413500a Mon Sep 17 00:00:00 2001 From: regnat Date: Tue, 18 May 2021 13:54:05 +0200 Subject: [PATCH] Restore an accidentally suppressed negation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Accidentally removed in ca96f5219489c1002499bfe2c580fdd458219144. This caused `nix run` to systematically fail with ``` error: app program '/nix/store/…' is not in the Nix store ``` --- src/nix/app.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nix/app.cc b/src/nix/app.cc index bdc64a886..01a0064db 100644 --- a/src/nix/app.cc +++ b/src/nix/app.cc @@ -112,7 +112,7 @@ App UnresolvedApp::resolve(ref store) auto builtContext = build(store, Realise::Outputs, installableContext); res.program = resolveString(*store, unresolved.program, builtContext); - if (store->isInStore(res.program)) + if (!store->isInStore(res.program)) throw Error("app program '%s' is not in the Nix store", res.program); return res;