1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4595],{90166:function(e,t,n){"use strict";n.r(t);var r=n(50029),o=n(87794),u=n.n(o),s=n(67294),i=n(11163),f=n(18300),a=n(82884),c=n(603),l=n(76713),d=n(78807),p=n(93066),j=n(98214),_=n(88599),g=n(85893);t.default=function(){var e,t=(0,i.useRouter)(),n=(0,p.Z)().user,o=(0,j.Z)(),h=o.loading,v=o.projects,E=o.revalidate,Z=(0,s.useState)(""),x=Z[0],w=Z[1],k=(0,s.useState)(""),m=k[0],b=k[1],N=(0,s.useMemo)(function(){if(h)return null;var e=c.Z.getAllFlattenedEfforts(v).find(function(e){return e.slug===t.query.effortSlug});return e?_.Z.enforceType(e,1,!1):null},[v,t]),y=(e=(0,r.Z)(u().mark(function e(r){var o,s;return u().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return w("Updating effort..."),b(""),e.prev=2,o=r.project.id>=0?r.project.id:{name:r.project.name,visibility:r.project.visibility},e.next=6,d.Z.update(v,r,o,(null==n?void 0:n.token)||"",w);case 6:s=e.sent,E(),w("Done!"),t.push("/effort/".concat(s.slug)),e.next=17;break;case 12:e.prev=12,e.t0=e.catch(2),console.error(e.t0.message),b(e.t0.message),w("");case 17:case"end":return e.stop()}},e,null,[[2,12]])})),function(t){return e.apply(this,arguments)});return N?(0,g.jsxs)(f.Z,{children:[(0,g.jsx)(a.Z,{title:"Edit Effort"}),(0,g.jsx)(l.Z,{effort:N,projects:v,onValidationPassed:y,loading:x}),m?(0,g.jsx)("p",{className:"text-red-300",children:m}):null]}):(0,g.jsx)(f.Z,{children:(0,g.jsx)(a.Z,{title:"Edit Effort",subtitle:"".concat(h?"Loading...":"Effort not found!")})})}},48359:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/effort/[effortSlug]/edit",function(){return n(90166)}])}},function(e){e.O(0,[5445,5737,2512,5724,766,1737,5504,9774,2888,179],function(){return e(e.s=48359)}),_N_E=e.O()}]);
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.