From 069752cb42948f5f19a357c7f11e384cb83d098e Mon Sep 17 00:00:00 2001 From: Alexander Neumann Date: Mon, 15 May 2017 23:35:52 +0200 Subject: [PATCH] Make layout default Dirname() consistent Always return a trailing slash now. --- src/restic/backend/layout_default.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/restic/backend/layout_default.go b/src/restic/backend/layout_default.go index 77cb27508..836700b33 100644 --- a/src/restic/backend/layout_default.go +++ b/src/restic/backend/layout_default.go @@ -24,10 +24,10 @@ func (l *DefaultLayout) Dirname(h restic.Handle) string { p := defaultLayoutPaths[h.Type] if h.Type == restic.DataFile && len(h.Name) > 2 { - p = l.Join(p, h.Name[:2]) + p = l.Join(p, h.Name[:2]) + "/" } - return l.Join(l.Path, p) + return l.Join(l.Path, p) + "/" } // Filename returns a path to a file, including its name.