Debug take an effect only if --verbose greater than 0 is specified
(level int, args ...interface{})
| 231 | |
| 232 | // Debug take an effect only if --verbose greater than 0 is specified |
| 233 | func Debug(level int, args ...interface{}) { |
| 234 | if Settings.Verbose >= level { |
| 235 | debugMutex.Lock() |
| 236 | defer debugMutex.Unlock() |
| 237 | now := time.Now() |
| 238 | diff := now.Sub(previousDebugTime) |
| 239 | previousDebugTime = now |
| 240 | fmt.Fprintf(os.Stderr, "[DEBUG][elapsed %s]: ", diff) |
| 241 | fmt.Fprintln(os.Stderr, args...) |
| 242 | } |
| 243 | } |
no outgoing calls
no test coverage detected