MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / uuid

Function uuid

wxapp/hisense_aijia.js:113–120  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

111}
112
113function uuid() {
114 if (crypto.randomUUID) return crypto.randomUUID();
115 return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c) => {
116 const r = (Math.random() * 16) | 0;
117 const v = c === "x" ? r : (r & 0x3) | 0x8;
118 return v.toString(16);
119 });
120}
121
122function generateDeviceId() {
123 const identifier = (`0${MINI_ID}0${Date.now().toString(16)}${randHex(8)}${randHex(8)}`).slice(0, 32);

Callers 2

pureGuidFunction · 0.70
loginByPhoneAuthMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected