diff --git a/hledger/Hledger/Cli/Commands/Close.hs b/hledger/Hledger/Cli/Commands/Close.hs index 299e695a4..41350287a 100755 --- a/hledger/Hledger/Cli/Commands/Close.hs +++ b/hledger/Hledger/Cli/Commands/Close.hs @@ -102,11 +102,10 @@ close CliOpts{rawopts_=rawopts, reportspec_=rspec'} j = do -- should we show the amount(s) on the equity posting(s) ? explicit = boolopt "explicit" rawopts - show_costs = boolopt "show-costs" rawopts -- the balances to close (acctbals',_) = balanceReport rspec j - acctbals = map (\(a,_,_,b) -> (a, if show_costs then b else mixedAmountStripPrices b)) acctbals' + acctbals = map (\(a,_,_,b) -> (a, if show_costs_ ropts then b else mixedAmountStripPrices b)) acctbals' totalamt = maSum $ map snd acctbals -- since balance assertion amounts are required to be exact, the diff --git a/hledger/Hledger/Cli/Commands/Print.hs b/hledger/Hledger/Cli/Commands/Print.hs index aecd10a9f..d32a3afb8 100644 --- a/hledger/Hledger/Cli/Commands/Print.hs +++ b/hledger/Hledger/Cli/Commands/Print.hs @@ -88,8 +88,8 @@ entriesReportAsText opts = -- By default, use the original as-written-in-the-journal txn. | otherwise = originalTransaction maybeStripPrices - -- Strip prices when inferring equity, unless the show-costs option is set - | opts ^. infer_equity && not (boolopt "show-costs" $ rawopts_ opts) = + -- Strip prices when inferring equity, unless the show_costs_ is set + | opts ^. infer_equity && not (opts ^. show_costs) = transactionTransformPostings postingStripPrices | otherwise = id