From 4840b366bc0511b08151e736b7ef357297cc2723 Mon Sep 17 00:00:00 2001 From: atl3 Date: Tue, 23 Jan 2024 15:44:01 +0100 Subject: [PATCH] Include support to Mojolicious relaxed placeholders (#17633) --- .../Javascript/libraries/javascript/ApiClient.mustache | 2 +- samples/client/petstore/javascript-es6/src/ApiClient.js | 2 +- samples/client/petstore/javascript-promise-es6/src/ApiClient.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/Javascript/libraries/javascript/ApiClient.mustache b/modules/openapi-generator/src/main/resources/Javascript/libraries/javascript/ApiClient.mustache index c3f9993e0d..542398b7f0 100644 --- a/modules/openapi-generator/src/main/resources/Javascript/libraries/javascript/ApiClient.mustache +++ b/modules/openapi-generator/src/main/resources/Javascript/libraries/javascript/ApiClient.mustache @@ -160,7 +160,7 @@ class ApiClient { url = apiBasePath + path; } - url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => { + url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => { var value; if (pathParams.hasOwnProperty(key)) { value = this.paramToString(pathParams[key]); diff --git a/samples/client/petstore/javascript-es6/src/ApiClient.js b/samples/client/petstore/javascript-es6/src/ApiClient.js index 8c58f5c491..271dc70cf0 100644 --- a/samples/client/petstore/javascript-es6/src/ApiClient.js +++ b/samples/client/petstore/javascript-es6/src/ApiClient.js @@ -159,7 +159,7 @@ class ApiClient { url = apiBasePath + path; } - url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => { + url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => { var value; if (pathParams.hasOwnProperty(key)) { value = this.paramToString(pathParams[key]); diff --git a/samples/client/petstore/javascript-promise-es6/src/ApiClient.js b/samples/client/petstore/javascript-promise-es6/src/ApiClient.js index 44d8c46bc3..12762f0d47 100644 --- a/samples/client/petstore/javascript-promise-es6/src/ApiClient.js +++ b/samples/client/petstore/javascript-promise-es6/src/ApiClient.js @@ -159,7 +159,7 @@ class ApiClient { url = apiBasePath + path; } - url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => { + url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => { var value; if (pathParams.hasOwnProperty(key)) { value = this.paramToString(pathParams[key]);