Skip to content
This repository was archived by the owner on Aug 31, 2018. It is now read-only.

Commit b6b71c5

Browse files
damiancaddaleax
authored andcommitted
doc: replace methods used in the example code
Methods `buf.writeUIntLE()` and `buf.writeUIntBE()` were used in the example code for the section of the methods `writeIntLE()` and `writeIntBE()` instead of the latter. PR-URL: nodejs/node#16416 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Vse Mozhet Byt <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent 24c95c5 commit b6b71c5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/api/buffer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -2383,12 +2383,12 @@ Examples:
23832383
```js
23842384
const buf = Buffer.allocUnsafe(6);
23852385

2386-
buf.writeUIntBE(0x1234567890ab, 0, 6);
2386+
buf.writeIntBE(0x1234567890ab, 0, 6);
23872387

23882388
// Prints: <Buffer 12 34 56 78 90 ab>
23892389
console.log(buf);
23902390

2391-
buf.writeUIntLE(0x1234567890ab, 0, 6);
2391+
buf.writeIntLE(0x1234567890ab, 0, 6);
23922392

23932393
// Prints: <Buffer ab 90 78 56 34 12>
23942394
console.log(buf);

0 commit comments

Comments
 (0)