static verify(message, signature, publicKey) { const msg = Util.wrapBuffer(message); const sig = Util.bufferKey(signature); const result = nacl.sign.detached.verify(msg, sig, publicKey); if (!result) { throw new Error( Invalid signature ${signature} on message ${message} with pk ${publicKey}); } }
The above function from the Crypto class does not return anything when the result is true.