3
0

Include wrapped error in JSON error payload

This commit is contained in:
Denis Arh
2020-11-06 11:51:04 +01:00
parent d75f813388
commit 873fc46556
+2
View File
@@ -7,9 +7,11 @@ func (e Error) MarshalJSON() ([]byte, error) {
Message string `json:"message"`
Meta meta `json:"meta,omitempty"`
Stack []*frame `json:"stack,omitempty"`
Wrap error `json:"wrap,omitempty"`
}{
Message: e.Error(),
Meta: e.meta,
Stack: e.stack,
Wrap: e.wrap,
})
}