mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
adjust formatting remote location
This commit is contained in:
parent
491f7636f8
commit
fbfc90fd1e
|
@ -57,6 +57,9 @@ func parseNoBucketLocation(remote string) (loc *remote_pb.RemoteStorageLocation)
|
||||||
}
|
}
|
||||||
|
|
||||||
func FormatLocation(loc *remote_pb.RemoteStorageLocation) string {
|
func FormatLocation(loc *remote_pb.RemoteStorageLocation) string {
|
||||||
|
if loc.Bucket == "" {
|
||||||
|
return fmt.Sprintf("%s%s", loc.Name, loc.Path)
|
||||||
|
}
|
||||||
return fmt.Sprintf("%s/%s%s", loc.Name, loc.Bucket, loc.Path)
|
return fmt.Sprintf("%s/%s%s", loc.Name, loc.Bucket, loc.Path)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue