From ba923e2864da7aae864a4a3d9185212092339142 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Sun, 23 Dec 2018 18:20:11 -0800 Subject: [PATCH] error if the last arguement does not end with forward slash --- weed/command/filer_copy.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/weed/command/filer_copy.go b/weed/command/filer_copy.go index 46bf61383..2d318bc1a 100644 --- a/weed/command/filer_copy.go +++ b/weed/command/filer_copy.go @@ -80,7 +80,8 @@ func runCopy(cmd *Command, args []string) bool { } urlPath := filerUrl.Path if !strings.HasSuffix(urlPath, "/") { - urlPath = urlPath + "/" + fmt.Printf("The last argument should be a folder and end with \"/\": %v\n", err) + return false } if filerUrl.Port() == "" {