"use strict";const a=require("./index.cjs227.js"),u=require("./index.cjs312.js"),f=require("./index.cjs313.js"),b=require("./index.cjs314.js"),l=require("./index.cjs238.js"),i={http:u,xhr:f,fetch:b};a.forEach(i,(e,r)=>{if(e){try{Object.defineProperty(e,"name",{value:r})}catch{}Object.defineProperty(e,"adapterName",{value:r})}});const d=e=>`- ${e}`,w=e=>a.isFunction(e)||e===null||e===!1,m={getAdapter:e=>{e=a.isArray(e)?e:[e];const{length:r}=e;let o,n;const c={};for(let t=0;t<r;t++){o=e[t];let s;if(n=o,!w(o)&&(n=i[(s=String(o)).toLowerCase()],n===void 0))throw new l(`Unknown adapter '${s}'`);if(n)break;c[s||"#"+t]=n}if(!n){const t=Object.entries(c).map(([h,p])=>`adapter ${h} `+(p===!1?"is not supported by the environment":"is not available in the build"));let s=r?t.length>1?`since :
`+t.map(d).join(`
`):" "+d(t[0]):"as no adapter specified";throw new l("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return n},adapters:i};module.exports=m;
//# sourceMappingURL=index.cjs242.js.map
