Skip to content

Commit 458d9a8

Browse files
tniessentargos
authored andcommitted
buffer: remove unnecessary assignment in fromString
The assignment to the encoding variable has no effect. Refs: #29217 PR-URL: #50199 Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 5c56081 commit 458d9a8

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

lib/buffer.js

-1
Original file line numberDiff line numberDiff line change
@@ -475,7 +475,6 @@ function fromString(string, encoding) {
475475
if (string.length === 0)
476476
return new FastBuffer();
477477
ops = encodingOps.utf8;
478-
encoding = undefined;
479478
} else {
480479
ops = getEncodingOps(encoding);
481480
if (ops === undefined)

0 commit comments

Comments
 (0)