scottvonduhn
09/18/2019, 2:45 PMJSON.parse(context.value)
replace it with JSON.parse(context.values[0])
and it should then work just the same as the map stage, but with more governance allowance.ganoo7
09/18/2019, 3:01 PMscottvonduhn
09/18/2019, 3:05 PMscottvonduhn
09/18/2019, 3:07 PMvalue
, whereas reduce is designed to process multiple values
. Even if you only have one value (usually because you skipped the map stage), it's still wrapped in the values
array, which is why you have to use values[0]
to retrieve it instead.scottvonduhn
09/18/2019, 3:10 PMganoo7
09/18/2019, 3:12 PMscottvonduhn
09/18/2019, 3:14 PMganoo7
09/18/2019, 6:01 PM