Open nrchandan opened 7 years ago
Addresses issue #4
Will push this again after rebasing with the latest master.
Yes, indeed interfaces are the right way to abstract hard-linked contracts (i.e. contracts imported in other contracts and therefore wired in their upgrade) and this is a simple implementation of it, however the full model is a factory pattern we use that I thought a little overly complex to demonstrate in the article, see https://github.com/elenadimitrova/ContractFactory/issues/4#issuecomment-312585426
The Parent contract is now coded to an Organisation interface rather than its implementation. This enables upgrading of the Organisation contract as long as the ABI doesn't change. This also implies that Parent can no longer create Organisations. In this implementation, Organisation needs to be instantiated by the user and passed on to the Parent contract for registering or upgrading.