File tree Expand file tree Collapse file tree 1 file changed +1
-11
lines changed Expand file tree Collapse file tree 1 file changed +1
-11
lines changed Original file line number Diff line number Diff line change @@ -353,10 +353,6 @@ export class UUID extends Binary {
353
353
}
354
354
}
355
355
356
- /**
357
- * Generate a 16 byte uuid v4 buffer used in UUIDs
358
- */
359
-
360
356
/**
361
357
* Returns the UUID id as a 32 or 36 character hex string representation, excluding/including dashes (defaults to 36 character dash separated)
362
358
* @param includeDashes - should the string exclude dash-separators.
@@ -455,13 +451,7 @@ export class UUID extends Binary {
455
451
return false ;
456
452
}
457
453
458
- try {
459
- // get this byte as hex: xxxxxxxx-xxxx-XXxx-xxxx-xxxxxxxxxxxx
460
- // check first part as uuid version: xxxxxxxx-xxxx-Xxxx-xxxx-xxxxxxxxxxxx
461
- return parseInt ( input [ 6 ] . toString ( 16 ) [ 0 ] , 10 ) === Binary . SUBTYPE_UUID ;
462
- } catch {
463
- return false ;
464
- }
454
+ return ( input [ 6 ] & 0xf0 ) === 0x40 ;
465
455
}
466
456
467
457
return false ;
You can’t perform that action at this time.
0 commit comments