Current returns the active home client instance, if any.
()
| 11 | |
| 12 | // Current returns the active home client instance, if any. |
| 13 | func Current() *Client { |
| 14 | if v := currentClient.Load(); v != nil { |
| 15 | if client, ok := v.(*Client); ok { |
| 16 | return client |
| 17 | } |
| 18 | } |
| 19 | return nil |
| 20 | } |
| 21 | |
| 22 | // ClearCurrent removes the active home client. |
| 23 | func ClearCurrent() { |
no test coverage detected