Files
argo-cd/errors/errors.go
2019-05-15 09:24:35 -07:00

17 lines
283 B
Go

package errors
import (
log "github.com/sirupsen/logrus"
)
// CheckError is a convenience function to exit if an error is non-nil and exit if it was
func CheckError(err error) {
if err != nil {
log.Fatal(err)
}
}
func FailOnErr(_ interface{}, err error) {
CheckError(err)
}