mirror of
https://github.com/node-red/node-red.git
synced 2025-12-27 07:31:07 +01:00
fixes #5251 The code changed from 4.0.x to 4.1.x This change to to prevent making changes to the orginial input `msg` object incase any values were stored in context (pass by refernce). The change meant that for every output message the whole original input `msg` was being cloned, which could be huge, causing a big performance regresion. This fix ensures the clone of the orginial `msg` is only done once and the much smaller output message is then cloned again to update `msg.parts` object for each output. This results in lots of small clones rather than lots of very large clones.