Create separate interface for object information.

Take out read-only information about a Fs in a separate struct to limit access.

See discussion at #282.
This commit is contained in:
klauspost
2016-02-19 13:31:09 +00:00
committed by Nick Craig-Wood
parent 85a0f25b95
commit ef06371c93
16 changed files with 190 additions and 95 deletions
+2 -2
View File
@@ -221,10 +221,10 @@ tryAgain:
if doUpdate {
actionTaken = "Copied (updated existing)"
err = dst.Update(in, src.ModTime(), src.Size())
err = dst.Update(in, src)
} else {
actionTaken = "Copied (new)"
dst, err = f.Put(in, src.Remote(), src.ModTime(), src.Size())
dst, err = f.Put(in, src)
}
inErr = in.Close()
}