diff --git a/src/lib/analytics/app/folder.ts b/src/lib/analytics/app/folder.ts index 014b8add..6d544acb 100644 --- a/src/lib/analytics/app/folder.ts +++ b/src/lib/analytics/app/folder.ts @@ -72,9 +72,17 @@ export default class Folder { public async create(body: CreateAppBody): Promise { if (this.serverVersion >= 55.0 && body.templateSourceId) { if (!body.templateOptions) { - body.templateOptions = { dynamicOptions: { productionType: 'ATF_3_0', runtimeLogEntryLevel: 'Warning' } }; + // eslint-disable-next-line no-param-reassign + body = { + ...body, + templateOptions: { dynamicOptions: { productionType: 'ATF_3_0', runtimeLogEntryLevel: 'Warning' } }, + }; } else if (!body.templateOptions.dynamicOptions) { - body.templateOptions.dynamicOptions = { productionType: 'ATF_3_0', runtimeLogEntryLevel: 'Warning' }; + // eslint-disable-next-line no-param-reassign + body.templateOptions = { + ...body.templateOptions, + dynamicOptions: { productionType: 'ATF_3_0', runtimeLogEntryLevel: 'Warning' }, + }; } } const response = await connectRequest(this.connection, { diff --git a/src/lib/analytics/query/query.ts b/src/lib/analytics/query/query.ts index 1009e622..e2837e2c 100644 --- a/src/lib/analytics/query/query.ts +++ b/src/lib/analytics/query/query.ts @@ -307,6 +307,7 @@ export default class QuerySvc { ux.table( records, columnNames.reduce>((all, name) => { + // eslint-disable-next-line no-param-reassign all[name] = { header: name, get: (row) => convertRowValue(row[name]) }; return all; }, {}) diff --git a/src/lib/analytics/utils.ts b/src/lib/analytics/utils.ts index c1ea59be..87fa78c6 100644 --- a/src/lib/analytics/utils.ts +++ b/src/lib/analytics/utils.ts @@ -63,6 +63,7 @@ export function generateTableColumns( if (mutute) { column = mutute(key, column); } + // eslint-disable-next-line no-param-reassign columns[key] = column; return columns; }, {}); diff --git a/test/.eslintrc.cjs b/test/.eslintrc.cjs index 37d088a8..9e3d7ff0 100644 --- a/test/.eslintrc.cjs +++ b/test/.eslintrc.cjs @@ -13,6 +13,7 @@ module.exports = { rules: { // Allow assert style expressions. i.e. expect(true).to.be.true 'no-unused-expressions': 'off', + 'no-param-reassign': 'off', 'mocha/no-identical-title': 'error', // Return types are defined by the source code. Allows for quick overwrites.