You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
website/util/errors.go

12 lines
123 B
Go

package util
import "log"
func Must[T any](value T, err error) T {
if err != nil {
log.Fatal(err)
}
return value
}