fabianbormann / cardano-peer-connect

This library aims to provide simple interfaces to implement CIP-0045 for dApps and wallets
Apache License 2.0
11 stars 4 forks source link

Make address in IDAppInfos not optional #41

Closed marcuspuchalla closed 1 year ago

marcuspuchalla commented 1 year ago

The address of a DApp should be a requirement and not optional in IDAppInfos.

Therefore I propose we change the constructor signature of DAppPeerConnect to only take name and url as IDAppInfos. Because a DApp cannot know its address at the start. It will only know its address if it provides a seed; in this case, the address would be redundant information in the constructor.

Later on, we set the address from the created meerkat instance automatically. When using the IDAppInfos interface, one would not have to check if the property exists and can rely on that information.

fabianbormann commented 1 year ago

done by merging #42 🎉