/**
 * Minified by jsDelivr using Terser v5.19.2.
 * Original file: /npm/adapter@1.0.0-beta.10/dist/index.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
"use strict";var __awaiter=this&&this.__awaiter||function(t,n,e,r){return new(e||(e=Promise))((function(u,i){function o(t){try{a(r.next(t))}catch(t){i(t)}}function c(t){try{a(r.throw(t))}catch(t){i(t)}}function a(t){t.done?u(t.value):new e((function(n){n(t.value)})).then(o,c)}a((r=r.apply(t,n||[])).next())}))},__generator=this&&this.__generator||function(t,n){var e,r,u,i,o={label:0,sent:function(){if(1&u[0])throw u[1];return u[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(e)throw new TypeError("Generator is already executing.");for(;o;)try{if(e=1,r&&(u=2&i[0]?r.return:i[0]?r.throw||((u=r.return)&&u.call(r),0):r.next)&&!(u=u.call(r,i[1])).done)return u;switch(r=0,u&&(i=[2&i[0],u.value]),i[0]){case 0:case 1:u=i;break;case 4:return o.label++,{value:i[1],done:!1};case 5:o.label++,r=i[1],i=[0];continue;case 7:i=o.ops.pop(),o.trys.pop();continue;default:if(!(u=o.trys,(u=u.length>0&&u[u.length-1])||6!==i[0]&&2!==i[0])){o=0;continue}if(3===i[0]&&(!u||i[1]>u[0]&&i[1]<u[3])){o.label=i[1];break}if(6===i[0]&&o.label<u[1]){o.label=u[1],u=i;break}if(u&&o.label<u[2]){o.label=u[2],o.ops.push(i);break}u[2]&&o.ops.pop(),o.trys.pop();continue}i=n.call(t,o)}catch(t){i=[6,t],r=0}finally{e=u=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}},_this=this;Object.defineProperty(exports,"__esModule",{value:!0}),exports.makeAdapter=function(t,n){void 0===n&&(n=null);var e={then:function(t){return t},catch:function(t){throw t},input:function(t){return Promise.reject(new Error('Input "'+t+'" must be supplied'))},output:function(){},inputBatch:function(t,n){return __awaiter(_this,void 0,void 0,(function(){var n,r,u,i,o,c,a,s,h,l;return __generator(this,(function(f){switch(f.label){case 0:for(u in n={},r=[],t)r.push(u);i=0,f.label=1;case 1:return i<r.length?(o=r[i],c=t[o],a="object"==typeof c?c.type:c,s="object"==typeof c?c.options:void 0,h=n,l=o,[4,e.input(o,a,s)]):[3,4];case 2:h[l]=f.sent(),f.label=3;case 3:return i++,[3,1];case 4:return[2,n]}}))}))}},r=function(){return t((n=e.input,n.batch=e.inputBatch,n),e.output).then(e.then).catch(e.catch);var n};return{exec:r,promise:r,then:function(t){return e.then=t,this},catch:function(t){return e.catch=t,this},output:function(t){return e.output=t,this},input:function(t){if("function"!=typeof t){var n=t;t=function(t){return Promise.resolve(n[t])}}return e.input=t,this},inputBatch:function(t){return e.inputBatch=t,this},attach:function(t){return Object.assign(e,t),this},meta:n}};
//# sourceMappingURL=/sm/77be679e1677208f6eb6f2e33717057fd19d3c5b02b75f3f1c7652ebc7bfaa64.map