Skip to content

Commit dacf239

Browse files
committed
fix(typescript-angular): update condition checks to explicitly compare with undefined
1 parent 1ac289b commit dacf239

File tree

19 files changed

+95
-95
lines changed

19 files changed

+95
-95
lines changed

modules/openapi-generator/src/main/resources/typescript-angular/configuration.mustache

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/others/typescript-angular/builds/composed-schemas-tagged-unions/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/others/typescript-angular/builds/composed-schemas/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v12-oneOf/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v12-provided-in-any/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v12-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v12-provided-in-root/builds/with-npm/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v13-oneOf/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v13-provided-in-any/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v13-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v13-provided-in-root/builds/with-npm/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v14-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v14-query-param-object-format/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v15-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v16-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

samples/client/petstore/typescript-angular-v17-provided-in-root/builds/default/configuration.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -70,19 +70,19 @@ constructor({ accessToken, apiKeys, basePath, credentials, encodeParam, encoder,
7070
if (apiKeys) {
7171
this.apiKeys = apiKeys;
7272
}
73-
if (username) {
73+
if (username !== undefined) {
7474
this.username = username;
7575
}
76-
if (password) {
76+
if (password !== undefined) {
7777
this.password = password;
7878
}
79-
if (accessToken) {
79+
if (accessToken !== undefined) {
8080
this.accessToken = accessToken;
8181
}
82-
if (basePath) {
82+
if (basePath !== undefined) {
8383
this.basePath = basePath;
8484
}
85-
if (withCredentials) {
85+
if (withCredentials !== undefined) {
8686
this.withCredentials = withCredentials;
8787
}
8888
if (encoder) {

0 commit comments

Comments
 (0)