From 73e92bcdb9f7d71a1f48ff5f90463e8a8eef9587 Mon Sep 17 00:00:00 2001 From: Mikhail Glushenkov Date: Mon, 15 Aug 2016 02:16:36 +0200 Subject: [PATCH] Use withPackageDB. --- cabal-install/Distribution/Client/Status.hs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/cabal-install/Distribution/Client/Status.hs b/cabal-install/Distribution/Client/Status.hs index 429c9c85567..97513dccb70 100644 --- a/cabal-install/Distribution/Client/Status.hs +++ b/cabal-install/Distribution/Client/Status.hs @@ -156,13 +156,7 @@ status verbosity globalFlags statusFlags = do return $ ( Just sandboxPath , Just $ sandboxPackageDBPath sandboxPath comp platform) else return (Nothing, Nothing) - let dbs :: [PackageDB] -- TODO: it might be better to inspect the currently - -- configured dbs instead of a static global,local,.. - dbs = GlobalPackageDB - : UserPackageDB - : case sandboxDbPath of - Nothing -> [] - Just p -> [SpecificPackageDB p] + let dbs = withPackageDB buildConfig let noFlags = not $ any Cabal.fromFlag [ statusVersion statusFlags , statusProgVersions statusFlags , statusCompiler statusFlags