diff --git a/public/js/src_modules/chartLine.mjs b/public/js/src_modules/chartLine.mjs
index 8a44bf108d29056b4c7eb4fdde17e40d02f8970a..cd698f90ad7d0ace0c27f16f74e27471bcfe5abd 100644
--- a/public/js/src_modules/chartLine.mjs
+++ b/public/js/src_modules/chartLine.mjs
@@ -33,10 +33,10 @@ const createSeriesOptionsForLineChart = function (
   buildingIdsPhenomenonNamesArr
 ) {
   // An array of colors, in hexadecimal format, provided by the global Highcharts object
-  const seriesColors = Highcharts.getOptions().colors;
+  const seriesColorsArr = Highcharts.getOptions().colors;
 
-  // Create a copy of the colors array
-  const seriesColorsArr = [...seriesColors];
+  // Create a local copy of the colors array
+  const seriesColorsForLineChartArr = [...seriesColorsArr];
 
   // Create an array of seriesOptions objects
   // Assumes that the observation array of arrays and building IDs + phenomenon names array are of equal length
@@ -53,7 +53,7 @@ const createSeriesOptionsForLineChart = function (
       return {
         name: `${buildingIdsPhenomenonNamesArr[i]}`,
         data: formattedObsArray,
-        color: seriesColorsArr[i],
+        color: seriesColorsForLineChartArr[i],
         turboThreshold: Number.MAX_VALUE, // #3404, remove after 4.0.5 release
       };
     });