| 1 | {"ast":null,"code":"'use strict';\n\nimport AxiosError from './AxiosError.js';\n\n/**\n * Resolve or reject a Promise based on response status.\n *\n * @param {Function} resolve A function that resolves the promise.\n * @param {Function} reject A function that rejects the promise.\n * @param {object} response The response.\n *\n * @returns {object} The response.\n */\nexport default function settle(resolve, reject, response) {\n const validateStatus = response.config.validateStatus;\n if (!response.status || !validateStatus || validateStatus(response.status)) {\n resolve(response);\n } else {\n reject(new AxiosError('Request failed with status code ' + response.status, response.status >= 400 && response.status < 500 ? AxiosError.ERR_BAD_REQUEST : AxiosError.ERR_BAD_RESPONSE, response.config, response.request, response));\n }\n}","map":{"version":3,"names":["AxiosError","settle","resolve","reject","response","validateStatus","config","status","ERR_BAD_REQUEST","ERR_BAD_RESPONSE","request"],"sources":["C:/Users/User/Downloads/medora5/frontend/node_modules/axios/lib/core/settle.js"],"sourcesContent":["'use strict';\n\nimport AxiosError from './AxiosError.js';\n\n/**\n * Resolve or reject a Promise based on response status.\n *\n * @param {Function} resolve A function that resolves the promise.\n * @param {Function} reject A function that rejects the promise.\n * @param {object} response The response.\n *\n * @returns {object} The response.\n */\nexport default function settle(resolve, reject, response) {\n const validateStatus = response.config.validateStatus;\n if (!response.status || !validateStatus || validateStatus(response.status)) {\n resolve(response);\n } else {\n reject(new AxiosError(\n 'Request failed with status code ' + response.status,\n response.status >= 400 && response.status < 500 ? AxiosError.ERR_BAD_REQUEST : AxiosError.ERR_BAD_RESPONSE,\n response.config,\n response.request,\n response\n ));\n }\n}\n"],"mappings":"AAAA,YAAY;;AAEZ,OAAOA,UAAU,MAAM,iBAAiB;;AAExC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,MAAMA,CAACC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,EAAE;EACxD,MAAMC,cAAc,GAAGD,QAAQ,CAACE,MAAM,CAACD,cAAc;EACrD,IAAI,CAACD,QAAQ,CAACG,MAAM,IAAI,CAACF,cAAc,IAAIA,cAAc,CAACD,QAAQ,CAACG,MAAM,CAAC,EAAE;IAC1EL,OAAO,CAACE,QAAQ,CAAC;EACnB,CAAC,MAAM;IACLD,MAAM,CAAC,IAAIH,UAAU,CACnB,kCAAkC,GAAGI,QAAQ,CAACG,MAAM,EACpDH,QAAQ,CAACG,MAAM,IAAI,GAAG,IAAIH,QAAQ,CAACG,MAAM,GAAG,GAAG,GAAGP,UAAU,CAACQ,eAAe,GAAGR,UAAU,CAACS,gBAAgB,EAC1GL,QAAQ,CAACE,MAAM,EACfF,QAAQ,CAACM,OAAO,EAChBN,QACF,CAAC,CAAC;EACJ;AACF","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]} |
|---|