Skip to content

Commit 1cca46a

Browse files
committed
fix(build): don't show Enterprise Cloud in the documentation URLs now we're using the Enterprise Cloud schema
1 parent 945d8c3 commit 1cca46a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

scripts/update-endpoints/fetch-json.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ const QUERY = `
3333

3434
main();
3535

36+
const removeEnterpriseCloudFromDocumentationUrl = (endpoint) => ({ ...endpoint, documentationUrl: endpoint.documentationUrl.replace('/enterprise-cloud@latest/', '') });
37+
3638
async function main() {
3739
const {
3840
data: { endpoints },
@@ -41,9 +43,11 @@ async function main() {
4143
ignoreChangesBefore: "2020-06-10",
4244
});
4345

46+
47+
4448
writeFileSync(
4549
path.resolve(__dirname, "generated", "endpoints.json"),
46-
prettier.format(JSON.stringify(endpoints), {
50+
prettier.format(JSON.stringify(endpoints.map(removeEnterpriseCloudFromDocumentationUrl)), {
4751
parser: "json",
4852
})
4953
);

0 commit comments

Comments
 (0)