diff options
author | Joe Mooring <[email protected]> | 2023-05-19 08:29:30 -0700 |
---|---|---|
committer | Bjørn Erik Pedersen <[email protected]> | 2023-05-20 11:14:18 +0200 |
commit | 150d190ff041f7da905afea7f3b9ca6bd4a31a48 (patch) | |
tree | df9d168c739494a02eeafd516a31e923fe70cc8d /docs | |
parent | 065ae003a5dc9173a1200fa1ab2d8927b002b1ab (diff) | |
download | hugo-150d190ff041f7da905afea7f3b9ca6bd4a31a48.tar.gz hugo-150d190ff041f7da905afea7f3b9ca6bd4a31a48.zip |
tpl/urls: Return empty string when JoinPath has zero args
Diffstat (limited to 'docs')
-rw-r--r-- | docs/content/en/functions/urls.JoinPath.md | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/docs/content/en/functions/urls.JoinPath.md b/docs/content/en/functions/urls.JoinPath.md index c0e0464b6..f11632367 100644 --- a/docs/content/en/functions/urls.JoinPath.md +++ b/docs/content/en/functions/urls.JoinPath.md @@ -1,6 +1,6 @@ --- title: urls.JoinPath -description: Joins the provided elements into a URL string and cleans the result of any ./ or ../ elements. +description: Joins the provided elements into a URL string and cleans the result of any ./ or ../ elements. If the argument list is empty, JoinPath returns an empty string. categories: [functions] menu: docs: @@ -10,6 +10,7 @@ signature: ["urls.JoinPath ELEMENT..."] --- ```go-html-template +{{ urls.JoinPath }} → "" {{ urls.JoinPath "" }} → "/" {{ urls.JoinPath "a" }} → "a" {{ urls.JoinPath "a" "b" }} → "a/b" |