Skip to content

Commit

Permalink
chore: migrate patch for @metamask/rpc-errors
Browse files Browse the repository at this point in the history
  • Loading branch information
legobeat committed Oct 22, 2024
1 parent 21c1360 commit 45873d6
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 19 deletions.
19 changes: 0 additions & 19 deletions patches/@metamask+rpc-errors+6.3.1.patch

This file was deleted.

38 changes: 38 additions & 0 deletions patches/@metamask+rpc-errors+7.0.0.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
diff --git a/node_modules/@metamask/rpc-errors/dist/classes.cjs b/node_modules/@metamask/rpc-errors/dist/classes.cjs
index 2cf07ef..63d76e8 100644
--- a/node_modules/@metamask/rpc-errors/dist/classes.cjs
+++ b/node_modules/@metamask/rpc-errors/dist/classes.cjs
@@ -56,9 +56,14 @@ class JsonRpcError extends Error {
serialized.data.cause = (0, utils_2.serializeCause)(this.data.cause);
}
}
+ /**
+ * passing the stack creates a loop, possible conflicting with hermes, since it's hermes that throws an error
+ */
+ /*
if (this.stack) {
serialized.stack = this.stack;
}
+ */
return serialized;
}
/**
diff --git a/node_modules/@metamask/rpc-errors/dist/classes.mjs b/node_modules/@metamask/rpc-errors/dist/classes.mjs
index 9d4c652..81f8518 100644
--- a/node_modules/@metamask/rpc-errors/dist/classes.mjs
+++ b/node_modules/@metamask/rpc-errors/dist/classes.mjs
@@ -57,9 +57,14 @@ export class JsonRpcError extends Error {
serialized.data.cause = serializeCause(this.data.cause);
}
}
+ /**
+ * passing the stack creates a loop, possible conflicting with hermes, since it's hermes that throws an error
+ */
+ /*
if (this.stack) {
serialized.stack = this.stack;
}
+ */
return serialized;
}
/**

0 comments on commit 45873d6

Please sign in to comment.