Skip to content

Commit 4840b36

Browse files
authored
Include support to Mojolicious relaxed placeholders (#17633)
1 parent 90bd1f3 commit 4840b36

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

modules/openapi-generator/src/main/resources/Javascript/libraries/javascript/ApiClient.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ class ApiClient {
160160
url = apiBasePath + path;
161161
}
162162

163-
url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => {
163+
url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => {
164164
var value;
165165
if (pathParams.hasOwnProperty(key)) {
166166
value = this.paramToString(pathParams[key]);

samples/client/petstore/javascript-es6/src/ApiClient.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ class ApiClient {
159159
url = apiBasePath + path;
160160
}
161161

162-
url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => {
162+
url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => {
163163
var value;
164164
if (pathParams.hasOwnProperty(key)) {
165165
value = this.paramToString(pathParams[key]);

samples/client/petstore/javascript-promise-es6/src/ApiClient.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ class ApiClient {
159159
url = apiBasePath + path;
160160
}
161161

162-
url = url.replace(/\{([\w-\.]+)\}/g, (fullMatch, key) => {
162+
url = url.replace(/\{([\w-\.#]+)\}/g, (fullMatch, key) => {
163163
var value;
164164
if (pathParams.hasOwnProperty(key)) {
165165
value = this.paramToString(pathParams[key]);

0 commit comments

Comments
 (0)