rumble-livestream-lib-go/error.go

15 lines
263 B
Go
Raw Permalink Normal View History

2023-12-08 18:55:04 +00:00
package rumblelivestreamlib
import "fmt"
const pkgName = "rumblelivestreamlib"
func pkgErr(prefix string, err error) error {
pkgErr := pkgName
if prefix != "" {
pkgErr = fmt.Sprintf("%s: %s", pkgErr, prefix)
}
return fmt.Errorf("%s: %v", pkgErr, err)
}