This module is set up in a weird way. destroyCircular
is called both when serializing and deserializing and it's doing two separate things:
The second part part is particularly problematic because during deserialization, this module is potentially dropping functions and all other "supported" types like buffer. This is unexpected:
deserializeError({
name: 'Error'
message: '💩',
data: new Buffer([1,2,3])
});
// [Error: 💩] with `data` property of value "[object Buffer]"
I'd expect the string "[object Buffer]"
when serializing an error, not during deserialization.
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too