diff --git a/dist/index.js b/dist/index.js index 4ab765973..79b1eac12 100644 --- a/dist/index.js +++ b/dist/index.js @@ -77278,7 +77278,7 @@ module.exports = VerifyStream; const path = __nccwpck_require__(71017); const fs = __nccwpck_require__(77758); const stripBom = __nccwpck_require__(88551); -const parseJson = __nccwpck_require__(86615); +const parseJson = __nccwpck_require__(81680); const pify = __nccwpck_require__(64810); const parse = (data, filePath, options = {}) => { @@ -77299,6 +77299,47 @@ module.exports["default"] = loadJsonFile; module.exports.sync = (filePath, options) => parse(fs.readFileSync(filePath, 'utf8'), filePath, options); +/***/ }), + +/***/ 81680: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +"use strict"; + +const errorEx = __nccwpck_require__(23505); +const fallback = __nccwpck_require__(55586); + +const JSONError = errorEx('JSONError', { + fileName: errorEx.append('in %s') +}); + +module.exports = (input, reviver, filename) => { + if (typeof reviver === 'string') { + filename = reviver; + reviver = null; + } + + try { + try { + return JSON.parse(input, reviver); + } catch (err) { + fallback(input, reviver); + + throw err; + } + } catch (err) { + err.message = err.message.replace(/\n/g, ''); + + const jsonErr = new JSONError(err); + if (filename) { + jsonErr.fileName = filename; + } + + throw jsonErr; + } +}; + + /***/ }), /***/ 11289: @@ -104584,47 +104625,6 @@ module.exports = pTry; module.exports["default"] = pTry; -/***/ }), - -/***/ 86615: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -"use strict"; - -const errorEx = __nccwpck_require__(23505); -const fallback = __nccwpck_require__(55586); - -const JSONError = errorEx('JSONError', { - fileName: errorEx.append('in %s') -}); - -module.exports = (input, reviver, filename) => { - if (typeof reviver === 'string') { - filename = reviver; - reviver = null; - } - - try { - try { - return JSON.parse(input, reviver); - } catch (err) { - fallback(input, reviver); - - throw err; - } - } catch (err) { - err.message = err.message.replace(/\n/g, ''); - - const jsonErr = new JSONError(err); - if (filename) { - jsonErr.fileName = filename; - } - - throw jsonErr; - } -}; - - /***/ }), /***/ 89808: