GetLogger return the internal logger, usually used in middleware.
()
| 567 | |
| 568 | // GetLogger return the internal logger, usually used in middleware. |
| 569 | func (c *Client) GetLogger() Logger { |
| 570 | if c.log != nil { |
| 571 | return c.log |
| 572 | } |
| 573 | c.log = createDefaultLogger() |
| 574 | return c.log |
| 575 | } |
| 576 | |
| 577 | // SetLogger set the customized logger for client, will disable log if set to nil. |
| 578 | func (c *Client) SetLogger(log Logger) *Client { |
nothing calls this directly
no test coverage detected