Skip to content

Commit

Permalink
Fix logger is override when debug is set to true (#83)
Browse files Browse the repository at this point in the history
  • Loading branch information
gearnode authored and rs committed Jun 13, 2019
1 parent 4763a1f commit 33ffc07
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cors.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func New(options Options) *Cors {
maxAge: options.MaxAge,
optionPassthrough: options.OptionsPassthrough,
}
if options.Debug {
if options.Debug && c.Log == nil {
c.Log = log.New(os.Stdout, "[cors] ", log.LstdFlags)
}

Expand Down

0 comments on commit 33ffc07

Please sign in to comment.