dev: Remove usage of partial NE.fromList

At this point, we're just giving a default for unpacking a Maybe
This commit is contained in:
gesh 2025-02-27 20:57:59 +02:00 committed by Simon Michael
parent cde77eace0
commit 3fa39c17b3

View File

@ -615,7 +615,7 @@ rawOptsToCliOpts rawopts = do
let iopts = rawOptsToInputOpts day usecolor postingaccttags rawopts
rspec <- either error' pure $ rawOptsToReportSpec day usecolor rawopts -- PARTIAL:
mtermwidth <- getTerminalWidth
let availablewidth = NE.head $ NE.fromList $ catMaybes [mtermwidth, Just defaultWidth] -- PARTIAL: fromList won't fail because non-null list
let availablewidth = fromMaybe defaultWidth mtermwidth
return defcliopts {
rawopts_ = rawopts
,command_ = command