Kristoffer Dalby 665a3cc666 add generic logerr func to shorten code
Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
2023-07-01 08:35:04 +01:00

8 lines
129 B
Go

package util
import "github.com/rs/zerolog/log"
func LogErr(err error, msg string) {
log.Error().Caller().Err(err).Msg(msg)
}