internal: add HTTPError.Unwrap
This allows callers to access the underlying error via errors.Unwrap.
This commit is contained in:
1 parent
25dfbaf95e
commit
8738a105fc
1 file changed
+4
@@ -100,6 +100,10 @@ func (err *HTTPError) Error() string {
|
||||
}
|
||||
}
|
||||
|
||||
func (err *HTTPError) Unwrap() error {
|
||||
return err.Err
|
||||
}
|
||||
|
||||
// DAVError is a XML error with HTTP status and a human readable message
|
||||
type DAVError struct {
|
||||
Code int
|
||||
|
||||
Reference in new issue
Block a user