summaryrefslogtreecommitdiffstats
path: root/modules/lfs/endpoint.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/lfs/endpoint.go')
-rw-r--r--modules/lfs/endpoint.go4
1 files changed, 1 insertions, 3 deletions
diff --git a/modules/lfs/endpoint.go b/modules/lfs/endpoint.go
index add16ce9f1..943966ed15 100644
--- a/modules/lfs/endpoint.go
+++ b/modules/lfs/endpoint.go
@@ -29,9 +29,7 @@ func endpointFromCloneURL(rawurl string) *url.URL {
return ep
}
- if strings.HasSuffix(ep.Path, "/") {
- ep.Path = ep.Path[:len(ep.Path)-1]
- }
+ ep.Path = strings.TrimSuffix(ep.Path, "/")
if ep.Scheme == "file" {
return ep