{"version":3,"sources":["webpack:///./node_modules/apollo-link-context/lib/bundle.esm.js"],"names":["setContext","setter","operation","forward","request","observer","handle","Promise","resolve","then","req","getContext","subscribe","next","bind","error","complete","catch","unsubscribe"],"mappings":"kIAAA,0FAGA,SAASA,EAAWC,GAChB,OAAO,IAAI,iBAAW,SAAUC,EAAWC,GACvC,IAAIC,EAAU,oBAAOF,EAAW,IAChC,OAAO,IAAI,QAAW,SAAUG,GAC5B,IAAIC,EAYJ,OAXAC,QAAQC,QAAQJ,GACXK,MAAK,SAAUC,GAAO,OAAOT,EAAOS,EAAKR,EAAUS,iBACnDF,KAAKP,EAAUF,YACfS,MAAK,WACNH,EAASH,EAAQD,GAAWU,UAAU,CAClCC,KAAMR,EAASQ,KAAKC,KAAKT,GACzBU,MAAOV,EAASU,MAAMD,KAAKT,GAC3BW,SAAUX,EAASW,SAASF,KAAKT,QAGpCY,MAAMZ,EAASU,MAAMD,KAAKT,IACxB,WACCC,GACAA,EAAOY","file":"js/npm.apollo-link-context~6743bf2f.168296c4.js","sourcesContent":["import { __rest } from 'tslib';\nimport { ApolloLink, Observable } from 'apollo-link';\n\nfunction setContext(setter) {\n return new ApolloLink(function (operation, forward) {\n var request = __rest(operation, []);\n return new Observable(function (observer) {\n var handle;\n Promise.resolve(request)\n .then(function (req) { return setter(req, operation.getContext()); })\n .then(operation.setContext)\n .then(function () {\n handle = forward(operation).subscribe({\n next: observer.next.bind(observer),\n error: observer.error.bind(observer),\n complete: observer.complete.bind(observer),\n });\n })\n .catch(observer.error.bind(observer));\n return function () {\n if (handle)\n handle.unsubscribe();\n };\n });\n });\n}\n\nexport { setContext };\n//# sourceMappingURL=bundle.esm.js.map\n"],"sourceRoot":""}