MCPcopy Create free account
hub / github.com/ICBNetwork/web3-Wallet / serializeError

Function serializeError

ppom/src/invoke-lib.js:1–7  ·  view source on GitHub ↗
(error)

Source from the content-addressed store, hash-verified

1function serializeError(error) {
2 const serialized = {};
3 Object.getOwnPropertyNames(error).forEach((key) => {
4 serialized[key] = error[key];
5 });
6 return serialized;
7}
8
9function deserializeError(data) {
10 const error = new Error(data.message);

Callers 1

invoke-lib.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected