Commit Graph

10 Commits

Author SHA1 Message Date
Bo-Yi Wu 787bff85e5 fix testing.
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
2016-12-11 10:14:23 +08:00
Roy Lou 4c4444b160 Write header immediately in AbortWithStatus()
Otherwise, caller needs to invoke WriteHeaderNow himself after
AbortWithStatus(), which is error-prone.

Also modified ErrorLoggerT() such that it always writes log to response
body. Otherwise calling AbortWithStatus() will fail to write body because
c.Writer.Written() is set true by WriteHeaderNow().
2016-04-15 00:02:29 +08:00
Manu Mtz.-Almeida e9531e5c76 Merge branch 'master' into develop 2016-01-26 20:08:28 +01:00
shadrus 13ba260d76 Wrong copy/paste TODO 2015-10-05 22:27:03 +03:00
Roman Zaynetdinov f13c3ae898 Add option to skip logging specified endpoints 2015-07-22 17:02:36 +03:00
Manu Mtz-Almeida c9272120b4 Adds unit tests for ErrorLogger() 2015-07-04 20:15:15 +02:00
Kevin Mulvey 7469025182 forgot the default of ColorForMethod 2015-05-27 20:53:28 -04:00
Kevin Mulvey 1b031cb271 Added tests for colorForMethod() and colorForStatus() 2015-05-27 20:36:37 -04:00
Manu Mtz-Almeida 99694bb716 Fixes errors 2015-05-12 15:22:13 +02:00
Manu Mtz-Almeida 0a192fb0fa Tons of unit tests 2015-04-09 12:15:02 +02:00