git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Merge pull request #1118 from hdgarrood/psc-publish-warnings

psc-publish: Don't print "Warnings:" unless there are warnings

commitb186d902eaf953f4066721bbc1dbbe804db21153 authorPhil Freeman <paf31@cantab.net> dateWed 13 May 2015, 17:33 (11 years ago) parentddae724f13cd3e
1 file changed+5−4
psc-publish/ErrorsWarnings.hs+5−4
psc-publish/ErrorsWarnings.hs+5−4
@@ -256,10 +256,11 @@ renderWarnings =
256256 where
257257 collectWarnings patterns warns =
258258 let boxes = mapMaybe (collectWarnings' warns) patterns
259− in vcat
260− [ para "Warnings:"
261− , indented (vcat (intersperse spacer boxes))
262− ]
259+ result = vcat
260+ [ para "Warnings:"
261+ , indented (vcat (intersperse spacer boxes))
262+ ]
263+ in if null boxes then nullBox else result
263264
264265 getResolutionNotVersion (ResolutionNotVersion n) = Just n
265266 getResolutionNotVersion _ = Nothing