mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 20:20:25 +03:00
Implement log package as drop-in replacement for handling Debug log-level
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
package log
|
||||
|
||||
import (
|
||||
internalLog "log"
|
||||
)
|
||||
|
||||
// Debug logging
|
||||
func Debug(args ...interface{}) {
|
||||
if verify(DebugLOG) {
|
||||
internalLog.Print(args...)
|
||||
}
|
||||
}
|
||||
|
||||
// Debugf formatted debug logging
|
||||
func Debugf(s string, args ...interface{}) {
|
||||
if verify(DebugLOG) {
|
||||
internalLog.Printf(s, args...)
|
||||
}
|
||||
}
|
||||
|
||||
// Debugln logging with newline
|
||||
func Debugln(args ...interface{}) {
|
||||
if verify(DebugLOG) {
|
||||
internalLog.Println(args...)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user