mirror of
https://github.com/nxshock/mssqlbulkloader.git
synced 2024-11-27 00:11:02 +05:00
22 lines
240 B
Go
22 lines
240 B
Go
package main
|
|
|
|
import (
|
|
"io"
|
|
"log"
|
|
"os"
|
|
)
|
|
|
|
type Logger struct {
|
|
silent bool
|
|
}
|
|
|
|
var logger *log.Logger
|
|
|
|
func initLogger(silent bool) {
|
|
if silent {
|
|
logger = log.New(io.Discard, "", 0)
|
|
} else {
|
|
logger = log.New(os.Stderr, "", 0)
|
|
}
|
|
}
|