A number of cleanups. Resisted several which were too opinionated and thought might be contentious. This resulted in a bug fix around len(review)
Fixes:
remove unnecessary casts
switch to non f formatting func for non formatting strings
added error handling for non-contentious instances
Things to think about:
There are casts out of mysql and postgress wich are not checked
The template.JS(s) is not escaped and likely should change to JSEscapeString or place a // no lint comment that it has been evaluated to be ok
The time.Time return from cachedIssueComments and cachedReviews is never used
cyclomatic complexity is high for hubbub/item.go:33 and hubbub/match.go:15. These should be refactor IHMO
A number of cleanups. Resisted several which were too opinionated and thought might be contentious. This resulted in a bug fix around
len(review)
Fixes:f
formatting func for non formatting stringsThings to think about:
JSEscapeString
or place a // no lint comment that it has been evaluated to be oktime.Time
return fromcachedIssueComments
andcachedReviews
is never usedhubbub/item.go:33
andhubbub/match.go:15
. These should be refactor IHMOSigned-off-by: Ken Sipe kensipe@gmail.com