PageSourceSearch

https://www.listening.com/assets/session-end-CwMRBy3h.js

js listening.com collected 2026-09-24 08:53:34 UTC 2,198 bytes, 2 lines download raw bytes

1import{Tt as e,dt as t,ln as n,pt as r}from"./exports-BeC_JQsX.js";import{Mn as i,Na as a,Tr as o,Zr as s,ii as c,ni as l,xn as u}from"./Schema-CAUmIdFq.js";import{r as d}from"./kvs-C_4L7zkd.js";import{i as f}from"./get-runtime-DbcBsDdd.js";import{t as p}from"./ManagedRuntime-5RiSlvNa.js";import{i as m,r as h,t as g}from"./Ref-BC_0t8wE.js";import{S as _,c as v,i as y}from"./client-Bp4NAKwM.js";var b=100;function x(i,a){let o=t(),s=r();if(!o)return;let{beforeBreadcrumb:c=null,maxBreadcrumbs:l=b}=o.getOptions();if(l<=0)return;let u={timestamp:e(),...i},d=c?n(()=>c(u,a)):u;d!==null&&(o.emit&&o.emit(`beforeAddBreadcrumb`,d,a),s.addBreadcrumb(d,l))}var S=class extends a()(`@listening/frontend/analytics/Analytics`){},C=class extends a()(`@listening/frontend/analytics/FeatureFlags`){},w={platform:`web`},T=c(S,S.of({identify:(e,t)=>o(()=>_.identify(e,t)),reset:o(()=>{_.reset(),y()}),capture:(e,t)=>o(()=>_.capture(e,{...w,...t}))}));c(C,C.of({getFlag:e=>o(()=>v(e)),hasLoadedFlags:o(()=>_.featureFlags?.hasLoadedFlags)}));var E=new Set([`verified_expiry`,`session_absence_confirmed`,`route_guard_no_session`,`unclassified`]);function D(e){return E.has(e)}function O({alreadyReported:e,cause:t,hadKnownSession:n}){return!D(t)||!n?!1:!e}var k=`listening.had_session`,A=e=>i(function*(){let t=yield*S,n=yield*h(!1),r=()=>e?.storage??d(),a=()=>{try{return r().getItem(k)===`1`}catch{return!1}},o=()=>{try{r().setItem(k,`1`)}catch{}},s=()=>{try{r().removeItem(k)}catch{}};return{rememberActiveSession:i(function*(){yield*m(n,!1),o()}),markSessionEnd:({cause:e,errorStatus:r=null})=>i(function*(){O({alreadyReported:yield*g(n),cause:e,hadKnownSession:a()})&&(yield*m(n,!0),yield*t.capture(`session_ended`,{cause:e,error_status:r,forced:D(e)})),s()})}}),j=class extends a()(`@listening/frontend/analytics/SessionTelemetry`,{make:A}){static layer=s(this,this.make())},M=f(`Listening/SessionTelemetryRuntime`,()=>p(j.layer.pipe(l(T))));function N(){M.runSync(u(j,e=>e.rememberActiveSession))}function P(e){x({category:`auth.session`,message:e.cause,level:D(e.cause)?`warning`:`info`}),M.runSync(u(j,t=>t.markSessionEnd(e)))}export{N as n,x as r,P as t};
2//# sourceMappingURL=session-end-CwMRBy3h.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.