validate added transaction before writing to file
This commit is contained in:
parent
393e7d98d4
commit
c521dc0bc2
@ -41,8 +41,8 @@ getAndAddTransactions l = (do
|
|||||||
,ltdescription=description
|
,ltdescription=description
|
||||||
,ltpostings=ps
|
,ltpostings=ps
|
||||||
}
|
}
|
||||||
appendToLedgerFile l $ show t
|
|
||||||
registerFromString (show t) >>= putStrLn
|
registerFromString (show t) >>= putStrLn
|
||||||
|
appendToLedgerFile l $ show t
|
||||||
liftM (t:) (getAndAddTransactions l)
|
liftM (t:) (getAndAddTransactions l)
|
||||||
) `catch` (\e -> if isEOFError e then return [] else ioError e)
|
) `catch` (\e -> if isEOFError e then return [] else ioError e)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user