Skip to content

Commit

Permalink
Ignore errors when resolving ENS resolver properties.
Browse files Browse the repository at this point in the history
  • Loading branch information
ricmoo committed Mar 9, 2022
1 parent be518c3 commit d160bac
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/providers/src.ts/base-provider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -383,11 +383,16 @@ export class Resolver implements EnsResolver {

try {
let result = await this.provider.call(tx);
if ((arrayify(result).length % 32) === 4) {
logger.throwError("resolver threw error", Logger.errors.CALL_EXCEPTION, {
transaction: tx, data: result
});
}
if (parseBytes) { result = _parseBytes(result, 0); }
return result;
} catch (error) {
if (error.code === Logger.errors.CALL_EXCEPTION) { return null; }
return null;
throw error;
}
}

Expand Down

0 comments on commit d160bac

Please sign in to comment.