LP#1858114: Fix thinko in template-parameter collection
authorMike Rylander <mrylander@gmail.com>
Fri, 14 Aug 2020 19:35:10 +0000 (15:35 -0400)
committerJason Boyer <JBoyer@EquinoxInitiative.org>
Mon, 15 Feb 2021 21:55:20 +0000 (16:55 -0500)
Minor thinko in the use of Array.prototype.concat() when gathering the
"where" and "having" template parameters -- concat() does not alter the
array it is called on, so we need to assign the result back to the
array.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Angela Kilsdonk <akilsdonk@equinoxinitiative.org>
Signed-off-by: Jason Boyer <JBoyer@EquinoxInitiative.org>
Open-ILS/web/reports/oils_rpt.js

index 3a75552..822217a 100644 (file)
@@ -154,7 +154,7 @@ oilsReport.prototype._gatherParams = function(params, arr, type, field) {
 
 oilsReport.prototype.gatherTemplateParams = function() {
     var arr = this.__gatherTemplateParams(this.def.where, 'where');
-    arr.concat(this.__gatherTemplateParams(this.def.having, 'having'));
+    arr = arr.concat(this.__gatherTemplateParams(this.def.having, 'having'));
     _debug("template params: " + js2JSON(arr));
     return arr;
 }