(data)
| 5609 | } |
| 5610 | |
| 5611 | function buildBuffer(data) { |
| 5612 | if (Array.isArray(data)) { |
| 5613 | const buffer = Buffer.allocUnsafe(data.length) |
| 5614 | data.forEach((v, k) => (buffer[k] = v)) |
| 5615 | return buffer |
| 5616 | } |
| 5617 | return null |
| 5618 | } |
| 5619 | |
| 5620 | const x = buildBuffer([0x81, 0xa3, 0x66, 0x6f, 0x6f, 0xa3, 0x62, 0x61, 0x72]) as any |
| 5621 |
no test coverage detected