Since the addHash function contains asynchronous code, it is possible to add the same hash into the pool more than once, if the function is called in short succession.
This fix checks that the hash is not in the pool after the asynchronous code has run.
Since the
addHash
function contains asynchronous code, it is possible to add the same hash into the pool more than once, if the function is called in short succession.This fix checks that the hash is not in the pool after the asynchronous code has run.