blockful-io / external-resolver

This project aims to scale the Ethereum Name Service (ENS) by consolidating existing patterns and proofs of concept into a unified and production-ready codebase.
MIT License
14 stars 3 forks source link

setName DB Resolver #133

Closed pikonha closed 3 months ago

pikonha commented 4 months ago

The setName and name functions aren't supposed to revert as the other functions specified by the EIP-5559 since it is used by the ETHRegistrarController when registering a 2LD on the L1.

See Tenderly TX trace

To fix this we opted for handling the domain name on-chain avoiding the unexpected revert which can be done by inhering the NameResolver:

contract DatabaseResolver is
    IERC165,
    IExtendedResolver,
    IWriteDeferral,
    AddrResolver,
    ABIResolver,
    PubkeyResolver,
    TextResolver,
    ContentHashResolver,
    NameResolver, <---
    Ownable
{}

The functions defined by the NameResolver shouldn't be overwritten.