From 82a10b096e148b77f2026240eba4f592986a4519 Mon Sep 17 00:00:00 2001 From: Edoardo Sabadelli Date: Thu, 10 Oct 2024 10:48:55 +0200 Subject: [PATCH] refactor: replace ||= operator, not transformed by Babel --- src/modules/pivotTable/PivotTableEngine.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/modules/pivotTable/PivotTableEngine.js b/src/modules/pivotTable/PivotTableEngine.js index 1753b4ce5..259a267c0 100644 --- a/src/modules/pivotTable/PivotTableEngine.js +++ b/src/modules/pivotTable/PivotTableEngine.js @@ -1084,7 +1084,8 @@ export class PivotTableEngine { // accumulating other value types like text values does not make sense if (isCumulativeValueType(valueType)) { // initialise to 0 for cumulative types - acc ||= 0 + // (||= is not transformed correctly in Babel with the current setup) + acc || (acc = 0) if (this.data[row] && this.data[row][column]) { const dataRow = this.data[row][column]