1
0
mirror of https://github.com/minio/mc.git synced 2026-01-04 02:44:40 +03:00

Move diff also away from prefixed url

This commit is contained in:
Harshavardhana
2015-06-06 21:49:48 -07:00
parent 3ee63f8d1b
commit 98a5cf648b
2 changed files with 1 additions and 8 deletions

View File

@@ -18,7 +18,6 @@ package main
import (
"path/filepath"
"strings"
"github.com/minio/mc/pkg/client"
"github.com/minio/minio/pkg/iodine"
@@ -114,12 +113,6 @@ func dodiffdirs(firstClnt client.Client, firstURL, secondURL string, recursive b
}
return
}
if recursive {
// this special handling is necessary since we are sending back absolute paths with in ListRecursive()
//
// To be consistent we have to filter them out
contentCh.Content.Name = strings.TrimPrefix(contentCh.Content.Name, strings.TrimSuffix(firstURL, "/")+"/")
}
newFirstURL, err := urlJoinPath(firstURL, contentCh.Content.Name)
if err != nil {
ch <- diff{

View File

@@ -141,7 +141,7 @@ func (s *MySuite) TestBucketOperations(c *C) {
err = s3c.SetBucketACL("public-read-write")
c.Assert(err, IsNil)
conf.HostURL = server.URL + "/"
conf.HostURL = server.URL + delimiter
s3c, err = New(conf)
c.Assert(err, IsNil)