Files
memecoin-botV2/.pnpm-store/v10/files/ab/922898800a13ab37968a964f17512dc58bdb03d2bdc59ee6fc27ffa4da2b6931350dfd383ee24c7ae4a90256651e9414490859ea38b934a7ac252efed62109

12 lines
308 B
Plaintext

import { createHash } from 'node:crypto';
function sha1(bytes) {
if (Array.isArray(bytes)) {
bytes = Buffer.from(bytes);
}
else if (typeof bytes === 'string') {
bytes = Buffer.from(bytes, 'utf8');
}
return createHash('sha1').update(bytes).digest();
}
export default sha1;