add: fix runtime printf error from 2nd txn on (fixes #164)
This commit is contained in:
parent
add9fee6db
commit
856f62b465
@ -96,8 +96,11 @@ getAndAddTransactions es@EntryState{..} = (do
|
|||||||
Nothing -> fail "urk ?"
|
Nothing -> fail "urk ?"
|
||||||
Just t -> do
|
Just t -> do
|
||||||
j <- if debug_ esOpts > 0
|
j <- if debug_ esOpts > 0
|
||||||
then hPrintf stderr "Skipping journal add due to debug mode.\n" >> return esJournal
|
then do hPrintf stderr "Skipping journal add due to debug mode.\n"
|
||||||
else journalAddTransaction esJournal esOpts t >> hPrintf stderr "Saved.\n"
|
return esJournal
|
||||||
|
else do j' <- journalAddTransaction esJournal esOpts t
|
||||||
|
hPrintf stderr "Saved.\n"
|
||||||
|
return j'
|
||||||
hPrintf stderr "Starting the next transaction (. or ctrl-D/ctrl-C to quit)\n"
|
hPrintf stderr "Starting the next transaction (. or ctrl-D/ctrl-C to quit)\n"
|
||||||
getAndAddTransactions es{esJournal=j, esDefDate=tdate t}
|
getAndAddTransactions es{esJournal=j, esDefDate=tdate t}
|
||||||
)
|
)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user