MCPcopy Create free account
hub / github.com/Ridter/cf_workers_proxy / isValidUUID

Function isValidUUID

js/worker.js:487–490  ·  view source on GitHub ↗

* This is not real UUID validation * @param {string} uuid

(uuid)

Source from the content-addressed store, hash-verified

485 * @param {string} uuid
486 */
487function isValidUUID(uuid) {
488 const uuidRegex = /^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;
489 return uuidRegex.test(uuid);
490}
491
492const WS_READY_STATE_OPEN = 1;
493const WS_READY_STATE_CLOSING = 2;

Callers 2

worker.jsFile · 0.85
stringifyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected