good morning!!!!

Skip to content
Snippets Groups Projects
Commit 68baf7e2 authored by Garet Halliday's avatar Garet Halliday
Browse files

wrapping a perror should return a perror

parent 4ef72066
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,9 @@ func Wrap(err error) Error { ...@@ -4,6 +4,9 @@ func Wrap(err error) Error {
if err == nil { if err == nil {
return nil return nil
} }
if perr, ok := err.(Error); ok {
return perr
}
return New( return New(
FATAL, FATAL,
InternalError, InternalError,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment