keelerrors

package
v0.18.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 5, 2024 License: MIT Imports: 0 Imported by: 1

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewWrappedError

func NewWrappedError(err, cause error) error

NewWrappedError returns a new wrapped error

Example
package main

import (
	"fmt"

	keelerrors "github.com/foomo/keel/errors"
	"github.com/pkg/errors"
)

func main() {
	parentErr := errors.New("parent")
	childErr := errors.New("child")
	wrappedErr := keelerrors.NewWrappedError(parentErr, childErr)
	fmt.Println(parentErr)
	fmt.Println(childErr)
	fmt.Println(wrappedErr)
}
Output:

parent
child
parent: child

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL