1"use strict";(self.webpackChunklearn_my_way=self.webpackChunklearn_my_way||[]).push([[789],{2789:(Q,S,i)=>{i.r(S),i.d(S,{SignInModule:()=>P});var O=i(316),I=i(2728),x=i(4240),V=i(4456),h=i(9916),t=i(7768);const y=(0,h.vy)({email:"",phoneNumber:"",passwordResetCode:"",pending:!1,previousRoute:"/"},(0,h.on)(t.I_,(e,{updatedSignIn:r})=>Object.assign({},e,{...r})),(0,h.on)(t.Wt,t.mQ,(e,{pending:r})=>Object.assign({},e,{pending:r})));function L(e,r){return y(e,r)}function H(e){return(r,v)=>(v.type===t.t&&(r=void 0),e(r,v))}var s=i(3321),p=i(4484),l=i(1493),u=i(1963),c=i(5443),E=i(9314),R=i(3602),g=i(1536),m=i(1198),U=i(5359),N=i(7719),d=i(8559),C=i(2270);let W=(()=>{var e;class r{constructor(o,a,G,w,J){this.actions$=o,this.authService=a,this.signInService=G,this.router=w,this.helpStoreService=J,this.userDoesNotExistError="Does not exist",this.userNoLmwRegistration="No LMW registration",this.userUnverifiedViaLMWError="User unverified via LMW",this.userUnverifiedViaOCNError="User unverified via OCN",this.updateSignInStore$=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.rs),(0,p.M)(()=>{this.signInService.dispatchUpdatingSignInStore(!0)}),(0,l.p)(n=>n.signInAttribute?this.checkUserExists(n):(0,g.of)(t.I_({updatedSignIn:n.updatedSignIn,relativeNavigation:n.relativeNavigation}))))),this.updateSignInNavigate$=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.I_),(0,p.M)(n=>{n.relativeNavigation&&this.router.navigate([n.relativeNavigation.nextState],{queryParamsHandling:"preserve",relativeTo:n.relativeNavigation.previousState}),this.signInService.dispatchUpdatingSignInStore(!1)})),{dispatch:!1}),this.updateSignInShowUnverifiedViaLMWHelp$=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.nE),(0,u.n)(n=>(0,g.of)(t.I_({updatedSignIn:n.updatedSignIn}),t.n3())))),this.updateSignInShowUnverifiedViaOCNHelp$=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.xL),(0,u.n)(n=>(0,g.of)(t.I_({updatedSignIn:n.updatedSignIn}),t.Jm())))),this.signInUser$=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.Y5),(0,p.M)(()=>{this.signInService.dispatchSigningInUser(!0)}),(0,l.p)(n=>this.authService.login(n.signInAttribute,n.password,n.clientMetaData).pipe((0,c.T)(()=>t.BP()),(0,E.W)(M=>(this.signInService.dispatchUpdatingSignInStore(!1),"Incorrect username or password."===M.message&&this.helpStoreService.dispatchUpdateHelpStore(t.as),(0,g.of)(t.wU({error:M})))))))),this.signInUserNavigate=(0,s.EH)(()=>this.actions$.pipe((0,s.gp)(t.BP),(0,u.n)(()=>this.signInService.selectSignInStore().pipe((0,R.s)(1))),(0,p.M)(n=>{this.router.navigateByUrl(n.previousRoute),this.signInService.dispatchSigningInUser(!1)})),{dispatch:!1})}checkUserExists(o){return this.authService.checkUserExists(o.signInAttribute).pipe((0,c.T)(a=>{if(a.userExists){if((0,N.$j)(a))throw new Error(this.userUnverifiedViaLMWError);if((0,N.RA)(a))throw new Error(this.userUnverifiedViaOCNError);if(a.registeredOnLmw)return t.I_({updatedSignIn:o.updatedSignIn,relativeNavigation:o.relativeNavigation});throw new Error(this.userNoLmwRegistration)}throw new Error(this.userDoesNotExistError)}),(0,E.W)(a=>(this.signInService.dispatchUpdatingSignInStore(!1),a.message===this.userDoesNotExistError?(this.helpStoreService.dispatchUpdateHelpStore(t.r1),(0,g.of)(t.Bl({error:a}))):a.message===this.userUnverifiedViaLMWError?(0,g.of)(t.nE({updatedSignIn:o.updatedSignIn})):a.message===this.userUnverifiedViaOCNError?(0,g.of)(t.xL({updatedSignIn:o.updatedSignIn})):a.message===this.userNoLmwRegistration?(0,g.of)(t.BO()):(this.router.navigateByUrl("/404"),(0,g.of)(t.Bl({error:a}))))))}}return(e=r).\u0275fac=function(o){return new(o||e)(d.KVO(s.En),d.KVO(m.R),d.KVO(U.O),d.KVO(I.Ix),d.KVO(C._))},e.\u0275prov=d.jDH({token:e,factory:e.\u0275fac}),r})();var B=i(7566),D=i(2136),j=i(164),f=i(6212),F=i(6428),K=i(1836),A=i(6616),T=i(784);let P=(()=>{var e;class r{}return(e=r).\u0275fac=function(o){return new(o||e)},e.\u0275mod=d.$C({type:e}),e.\u0275inj=d.G2t({providers:[m.R,B.b,D.F,j.s,U.O],imports:[O.MD,V.X1,f.fe,f.hp,f.d8,I.iI.forChild([...x.LR]),h.md.forFeature("signIn",L,{metaReducers:[H]}),s.Vm.forFeature([W]),F.G,K.T,A.C,T.a]}),r})()}}]); 2//# sourceMappingURL=789.e20a257f6b11c1d4.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.