Remove buffer dependency
This commit is contained in:
@@ -8,9 +8,9 @@ const MESSAGE_TYPE = numberToUint16BE(MessageTypes.Keepalive)
|
||||
* Create an outgoing keepalive (0x0005) packet.
|
||||
* @returns An outgoing keepalive (0x0005) packet.
|
||||
*/
|
||||
export function packKeepaliveMessage (): Buffer {
|
||||
export function packKeepaliveMessage (): Uint8Array {
|
||||
return packOutgoingPacket({
|
||||
messageType: MESSAGE_TYPE,
|
||||
data: Buffer.alloc(0)
|
||||
data: new Uint8Array(0)
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user