fixes
This commit is contained in:
@@ -14,7 +14,9 @@ const calculate_sha256 = (path) => {
|
||||
const hash = blake2b(32);
|
||||
|
||||
fs.createReadStream(path)
|
||||
.on('data', (data) => hash.update(data))
|
||||
.on('data', (data) => {
|
||||
return hash.update(new Uint8Array(data));
|
||||
})
|
||||
.on('error', (err) => reject(err))
|
||||
.on('end', () => {
|
||||
const h = hash.digest('hex');
|
||||
|
||||
Reference in New Issue
Block a user