Skip to content

Commit c9b9c13

Browse files
committed
fix deprecated buffer creation
1 parent 622302e commit c9b9c13

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/core/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ function shouldCompressBrotli(req) {
5555

5656
function hasGzipId12(gzipped, cb) {
5757
const stream = fs.createReadStream(gzipped, { start: 0, end: 1 });
58-
let buffer = Buffer('');
58+
let buffer = Buffer.from('');
5959
let hasBeenCalled = false;
6060

6161
stream.on('data', (chunk) => {

0 commit comments

Comments
 (0)