You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by mm...@apache.org on 2022/06/28 05:25:08 UTC

[pulsar-site] branch main updated: Remove trailing slash from clientVersionUrl (#125)

This is an automated email from the ASF dual-hosted git repository.

mmarshall pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pulsar-site.git


The following commit(s) were added to refs/heads/main by this push:
     new 26c93ce30e3 Remove trailing slash from clientVersionUrl (#125)
26c93ce30e3 is described below

commit 26c93ce30e3a960a6cc59b887ebda92b63e16462
Author: Michael Marshall <mm...@apache.org>
AuthorDate: Tue Jun 28 00:25:04 2022 -0500

    Remove trailing slash from clientVersionUrl (#125)
    
    In #124, I incorrectly included a trailing slash, which led to URLS getting generated with `//` at the end. This PR fixes that mistake.
---
 site2/website-next/scripts/replace.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/site2/website-next/scripts/replace.js b/site2/website-next/scripts/replace.js
index 3098156be75..f110f836c4a 100644
--- a/site2/website-next/scripts/replace.js
+++ b/site2/website-next/scripts/replace.js
@@ -97,7 +97,7 @@ function clientVersionUrl(version, type) {
   if ((majorVersion === 2 && minorVersion < 5) || (type === "python" && minorVersion >= 7)) {
     return `${siteConfig.url}/api/${type}/${version}`;
   } else if (majorVersion >= 2 && minorVersion >= 5) {
-    return `${siteConfig.url}/api/${type}/${majorVersion}.${minorVersion}.0-SNAPSHOT/`
+    return `${siteConfig.url}/api/${type}/${majorVersion}.${minorVersion}.0-SNAPSHOT`
   }
 }