| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent be63dc5 commit 878b2e7
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -52,11 +52,7 @@ function legacyWrite(algo, message, encoding, writes, len, outEnc) { | |||
| 52 | 52 | while (writes-- > 0) { | |
| 53 | 53 | const h = crypto.createHash(algo); | |
| 54 | 54 | h.update(message, encoding); | |
| 55 | - let res = h.digest(outEnc); | ||
| 56 | - | ||
| 57 | - // Include buffer creation costs for older versions | ||
| 58 | - if (outEnc === 'buffer' && typeof res === 'string') | ||
| 59 | - res = Buffer.from(res, 'binary'); | ||
| 55 | + h.digest(outEnc); | ||
| 60 | 56 | } | |
| 61 | 57 | ||
| 62 | 58 | bench.end(gbits); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments