iden3 / go-iden3-core

Go core implementation of the iden3 system
https://docs.iden3.io
Apache License 2.0
91 stars 33 forks source link

When Issuer.PublishState() fails in smart contract call, claims.AddLeafRootsTree may fail next time #379

Closed ed255 closed 4 years ago

ed255 commented 4 years ago

In the Issuer:

In PublishState a check is done to see if the current ClaimsTreeRoot is different than the ClaimsTreeRoot used in the published state; if so, the current ClaimsTreeRoot is added to the RootsTree.

If any further function fails, the next time PublishState is called, adding the ClaimsTreeRoot to the RootsTree will fail because the leaf will already be there.