UNPKG

@dcl/platform-server-commons

Version:
14 lines 393 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.parseJson = void 0; const errors_1 = require("../errors"); async function parseJson(request) { try { return (await request.json()); } catch (error) { throw new errors_1.InvalidRequestError('Invalid body'); } } exports.parseJson = parseJson; //# sourceMappingURL=parsing.js.map