Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
buffer: default to UTF8 in byteLength()
If an undefined encoding is passed to byteLength(), assume that it is UTF8 immediately. This yields a small speedup, as it prevents string operations on the encoding argument. PR-URL: #4010 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Trevor Norris <[email protected]>
- Loading branch information