From 449e303f2f61b7870e876cc963aa6d932df31204 Mon Sep 17 00:00:00 2001 From: Lucia Date: Thu, 8 Oct 2020 17:54:17 +0200 Subject: [PATCH] Change new Buffer to Buffer.from after deprecation --- src/core/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/utils.js b/src/core/utils.js index ad85013fed4..ff840e4e4db 100644 --- a/src/core/utils.js +++ b/src/core/utils.js @@ -623,7 +623,7 @@ export const btoa = (str) => { if (str instanceof Buffer) { buffer = str } else { - buffer = new Buffer(str.toString(), "utf-8") + buffer = Buffer.from(str.toString(), "utf-8") } return buffer.toString("base64")