mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-09 18:03:21 +00:00
ACS-11155: update conditional checks to use optional chaining (#11658)
- Modified several components to use optional chaining for safer property access, enhancing code robustness. - Updated ESLint configuration to enforce stricter rules on the use of optional chaining. - Adjusted tests to reflect changes in property access patterns.
This commit is contained in:
@@ -337,7 +337,7 @@ export class SuperagentHttpClient implements HttpClient {
|
||||
const newParams: { [key: string]: any } = {};
|
||||
|
||||
for (const key in params) {
|
||||
if (Object.prototype.hasOwnProperty.call(params, key) && params[key] !== undefined && params[key] !== null) {
|
||||
if (Object.prototype.hasOwnProperty.call(params, key) && params[key] != null) {
|
||||
const value = params[key];
|
||||
if (SuperagentHttpClient.isFileParam(value) || Array.isArray(value)) {
|
||||
newParams[key] = value;
|
||||
|
||||
Reference in New Issue
Block a user