Update buffer code to not get deprecation message

This commit is contained in:
Jan Oberhauser 2020-09-01 17:50:51 +02:00
parent 23f8b2b4df
commit a9bfb506ff

View file

@ -298,7 +298,7 @@ class App {
this.app.use((req: express.Request, res: express.Response, next: express.NextFunction) => {
(req as ICustomRequest).parsedUrl = parseUrl(req);
// @ts-ignore
req.rawBody = new Buffer('', 'base64');
req.rawBody = Buffer.from('', 'base64');
next();
});