Skip to content

Commit d8edf98

Browse files
committed
Updated readme
1 parent 9d653ce commit d8edf98

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,16 @@ func main() {
9898
// - err2 overwrites err1 source location to correctly show the location where err2 was executed
9999
err2 := errors.M(err1, errors.WithMeta("key2", "val2"))
100100

101-
fmt.Printf("%+v", errors.PrettyPrint(err2))
101+
fmt.Printf("%+v", errors.PrettyPrint(err2)) // PrettyPrint should only be used in development to have a nicer output
102+
/*
103+
output:
104+
105+
this is an error
106+
|- Source : /goprograms/errors/example_test.go:20
107+
|- Meta :
108+
|- key1 : val1
109+
|- key2 : val2
110+
*/
102111
}
103112
```
104113

0 commit comments

Comments
 (0)