import{b as m,c as p}from"./chunk-NJ5QGAXC.js";import{C as s,Oc as d,Rf as u,Z as n,aa as c,j as h}from"./chunk-4JM6MIZ5.js";import{i}from"./chunk-QJQRWPYR.js";var v=(()=>{let r=class r{authHttp;restExtractor;constructor(e,t){this.authHttp=e,this.restExtractor=t}getChapters(e){let t=m.buildVideoPasswordHeader(e.videoPassword);return this.authHttp.get(`${p.BASE_VIDEO_URL}/${e.videoId}/chapters`,{headers:t}).pipe(s(a=>this.restExtractor.handleError(a)))}updateChapters(e,t){if(t.shouldUpdateAPI()!==!0)return h(!0);let a={chapters:t.getChaptersForUpdate()};return this.authHttp.put(`${p.BASE_VIDEO_URL}/${e}/chapters`,a).pipe(s(f=>this.restExtractor.handleError(f)))}};i(r,"\u0275fac",function(t){return new(t||r)(c(d),c(u))}),i(r,"\u0275prov",n({token:r,factory:r.\u0275fac}));let o=r;return o})();export{v as a};
/**i18n:68865f44f2a527c44cf5136a17c76a0ff8308c2bae5c7c8d50070a5fb9847c44*/
//# sourceMappingURL=chunk-YUZI7KZO.js.map
