Skip to content

Commit

Permalink
Improve error logging
Browse files Browse the repository at this point in the history
  • Loading branch information
Akim Mamedov committed Mar 4, 2024
1 parent ac9b3cf commit cb7ab7b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/src/store/actions/governance.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export const setDelegatee = (address) => ({
});

export const setError = (message) => {
console.error(message);
let msg;
try {
const isEthJs = /ethjs-query/.test(message);
Expand All @@ -31,7 +32,6 @@ export const setError = (message) => {
.slice(0, -1),
)
: message;
console.log(parsedMessage);

const newMessage = isEthJs
? `${parsedMessage.value.data.message}. Error code: ${parsedMessage.value.code}`
Expand Down

0 comments on commit cb7ab7b

Please sign in to comment.