Skip to content
This repository has been archived by the owner on Aug 23, 2023. It is now read-only.

Commit

Permalink
Removed useless type assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
fkaleo committed Jan 31, 2020
1 parent 9a24472 commit 3e51444
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/middleware/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ func (rw *LoggingResponseWriter) Write(b []byte) (int, error) {
func Logger() macaron.Handler {
return func(ctx *Context) {
start := time.Now()
ctx.Resp = &LoggingResponseWriter{
rw := &LoggingResponseWriter{
ResponseWriter: ctx.Resp,
}
rw := ctx.Resp.(*LoggingResponseWriter)
ctx.Resp = rw
ctx.MapTo(ctx.Resp, (*http.ResponseWriter)(nil))
ctx.Next()

Expand Down

0 comments on commit 3e51444

Please sign in to comment.