@@ -1325,11 +1325,12 @@ changes:
1325
1325
-->
1326
1326
1327
1327
* ` value ` {string|Buffer|Uint8Array|integer} What to search for.
1328
- * ` byteOffset ` {integer} Where to begin searching in ` buf ` . ** Default:** ` 0 `
1329
- * ` encoding ` {string} If ` value ` is a string, this is its encoding.
1330
- ** Default:** ` 'utf8' `
1331
- * Returns: {integer} The index of the first occurrence of ` value ` in ` buf ` or ` -1 `
1332
- if ` buf ` does not contain ` value ` .
1328
+ * ` byteOffset ` {integer} Where to begin searching in ` buf ` . ** Default:** ` 0 ` .
1329
+ * ` encoding ` {string} If ` value ` is a string, this is the encoding used to
1330
+ determine the binary representation of the string that will be searched for in
1331
+ ` buf ` . ** Default:** ` 'utf8' ` .
1332
+ * Returns: {integer} The index of the first occurrence of ` value ` in ` buf ` , or
1333
+ ` -1 ` if ` buf ` does not contain ` value ` .
1333
1334
1334
1335
If ` value ` is:
1335
1336
@@ -1438,14 +1439,15 @@ changes:
1438
1439
1439
1440
* ` value ` {string|Buffer|Uint8Array|integer} What to search for.
1440
1441
* ` byteOffset ` {integer} Where to begin searching in ` buf ` .
1441
- ** Default:** [ ` buf.length ` ] ` - 1 `
1442
- * ` encoding ` {string} If ` value ` is a string, this is its encoding.
1443
- ** Default:** ` 'utf8' `
1444
- * Returns: {integer} The index of the last occurrence of ` value ` in ` buf ` or ` -1 `
1445
- if ` buf ` does not contain ` value ` .
1446
-
1447
- Identical to [ ` buf.indexOf() ` ] , except ` buf ` is searched from back to front
1448
- instead of front to back.
1442
+ ** Default:** [ ` buf.length ` ] ` - 1 ` .
1443
+ * ` encoding ` {string} If ` value ` is a string, this is the encoding used to
1444
+ determine the binary representation of the string that will be searched for in
1445
+ ` buf ` . ** Default:** ` 'utf8' ` .
1446
+ * Returns: {integer} The index of the last occurrence of ` value ` in ` buf ` , or
1447
+ ` -1 ` if ` buf ` does not contain ` value ` .
1448
+
1449
+ Identical to [ ` buf.indexOf() ` ] , except the last occurrence of ` value ` is found
1450
+ rather than the first occurrence.
1449
1451
1450
1452
Examples:
1451
1453
0 commit comments