Files
opencloud/extensions/webdav/pkg/net/net.go
Jörn Friedrich Dreyer 37f64eb0e8 Merge branch 'master' into search
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2022-04-14 11:56:26 +00:00

13 lines
212 B
Go

package net
import (
"net/url"
)
// EncodePath encodes the path of a url.
//
// slashes (/) are treated as path-separators.
func EncodePath(path string) string {
return (&url.URL{Path: path}).EscapedPath()
}