Don't fail on wrong log decoding (#5813)
This commit is contained in:
parent
57479dac27
commit
e4c7a7f30a
@ -177,6 +177,7 @@ export default class Contract {
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
const decoded = event.decodeLog(log.topics, log.data);
|
||||
|
||||
log.params = {};
|
||||
@ -190,6 +191,12 @@ export default class Contract {
|
||||
});
|
||||
|
||||
return log;
|
||||
} catch (error) {
|
||||
console.warn('Error decoding log', log);
|
||||
console.warn(error);
|
||||
|
||||
return null;
|
||||
}
|
||||
})
|
||||
.filter((log) => log);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user