iden3 / iden3js

Javascript client library of the iden3 system
GNU General Public License v3.0
25 stars 3 forks source link

Add read-write locks in nonceDB to fix data races #44

Closed ed255 closed 5 years ago

ed255 commented 5 years ago

Upon further inspection it seems we don't need a mutex in the nonceDB due to the single-threaded nature of javascript. Care must be taken in the future: if the nonceDB uses IO operations (for instance, if it's backed by an on-disk DB), a mutex will probably be required.