Safari-Wallet / core

17 stars 3 forks source link

Remove failable initializers in EthereumClient and AlchemyClient #19

Open ronaldmannak opened 2 years ago

ronaldmannak commented 2 years ago

Currently, EthereumClient and its subclass AlchemyClient have failable initalizers. The initializers return nil if the URL can't be created from the provided path string parameter. This shouldn't be a runtime error (unless we want the end-user to type in an end point like MetaMask allows, which I think we don't want).

I propose we change the initializers into non-failable initializers for simplicity.