mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-13 14:03:10 +02:00
8 lines
199 B
TypeScript
8 lines
199 B
TypeScript
|
const crypto = require('crypto');
|
||
|
|
||
|
export default (data: ArrayBuffer) => {
|
||
|
const buf = new Buffer(data);
|
||
|
const hash = crypto.createHash("md5");
|
||
|
hash.update(buf);
|
||
|
return hash.digest("hex");
|
||
|
};
|