first commit

This commit is contained in:
Kevand
2026-02-04 00:21:37 +00:00
commit 58925b1ac0
18 changed files with 1086 additions and 0 deletions

13
pb_hooks/util.js Normal file
View File

@@ -0,0 +1,13 @@
module.exports = {
uuidv4() {
const uuid = new Array(36);
for (let i = 0; i < 36; i++) {
uuid[i] = Math.floor(Math.random() * 16)
}
uuid[14] = 4;
uuid[19] = uuid[19] &= ~(1 << 2);
uuid[19] = uuid[19] |= (1 << 3);
uuid[8] = uuid[13] = uuid[18] = uuid[23] = '-';
return uuid.map(x => x.toString(16)).join('')
}
}