Username Link QR Code
This commit is contained in:
parent
68dfc46185
commit
e1d2dbd8ff
50 changed files with 2187 additions and 120 deletions
14
ts/test-mock/helpers.ts
Normal file
14
ts/test-mock/helpers.ts
Normal file
|
@ -0,0 +1,14 @@
|
|||
// Copyright 2023 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
export function bufferToUuid(buffer: Buffer): string {
|
||||
const hex = buffer.toString('hex');
|
||||
|
||||
return [
|
||||
hex.substring(0, 8),
|
||||
hex.substring(8, 12),
|
||||
hex.substring(12, 16),
|
||||
hex.substring(16, 20),
|
||||
hex.substring(20),
|
||||
].join('-');
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue