mirror of https://github.com/minio/minio.git
stop all console logging
This commit is contained in:
parent
56097dfca8
commit
e7baf2d7d2
|
@ -177,14 +177,16 @@ func initConsoleServer() (*restapi.Server, error) {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
noLog := func(string, ...interface{}) {
|
||||||
|
// nothing to log
|
||||||
|
}
|
||||||
|
|
||||||
// Initialize MinIO loggers
|
// Initialize MinIO loggers
|
||||||
restapi.LogInfo = logger.Info
|
restapi.LogInfo = noLog
|
||||||
restapi.LogError = logger.Error
|
restapi.LogError = noLog
|
||||||
|
|
||||||
api := operations.NewConsoleAPI(swaggerSpec)
|
api := operations.NewConsoleAPI(swaggerSpec)
|
||||||
api.Logger = func(_ string, _ ...interface{}) {
|
api.Logger = noLog
|
||||||
// nothing to log.
|
|
||||||
}
|
|
||||||
|
|
||||||
server := restapi.NewServer(api)
|
server := restapi.NewServer(api)
|
||||||
// register all APIs
|
// register all APIs
|
||||||
|
|
Loading…
Reference in New Issue