mirror of
https://github.com/restic/restic.git
synced 2025-10-17 07:22:07 +00:00
Shorten error message for tree errors
This commit is contained in:
@@ -204,14 +204,14 @@ type Error struct {
|
||||
|
||||
func (e Error) Error() string {
|
||||
if e.BlobID != nil && e.TreeID != nil {
|
||||
msg := "tree " + e.TreeID.String()
|
||||
msg += ", blob " + e.BlobID.String()
|
||||
msg := "tree " + e.TreeID.Str()
|
||||
msg += ", blob " + e.BlobID.Str()
|
||||
msg += ": " + e.Err.Error()
|
||||
return msg
|
||||
}
|
||||
|
||||
if e.TreeID != nil {
|
||||
return "tree " + e.TreeID.String() + ": " + e.Err.Error()
|
||||
return "tree " + e.TreeID.Str() + ": " + e.Err.Error()
|
||||
}
|
||||
|
||||
return e.Err.Error()
|
||||
|
Reference in New Issue
Block a user