PageSourceSearch

https://www.boostmobile.com/shop/static/version1790157662/frontend…/js/sales-agent-redirect.min.js

js boostmobile.com collected 2026-09-24 08:54:10 UTC 1,799 bytes, 7 lines download raw bytes

1(function(){try{if(!document.cookie||typeof document.cookie!=='string'){return;}
2const cookies=document.cookie.split(';');let hasCookie=false;try{hasCookie=cookies.some(cookie=>{const trimmed=cookie?cookie.trim():'';return trimmed&&trimmed.startsWith('harmonyRetailUserId=');});}catch(cookieError){console.error('Cookie parsing failed:',cookieError);return;}
3if(hasCookie&&!window.location.href.includes('/boostmobile_sales_agent/')){try{if(!window.location.origin||!window.location.pathname){console.error('Invalid window.location properties');return;}
4const trustedDomains=['dish.com','boostmobile.com'];const originDomain=new URL(window.location.origin).hostname;if(!trustedDomains.some(domain=>originDomain===domain||originDomain.endsWith('.'+domain))){console.error('Untrusted domain detected');return;}
5let origin=(window.location.origin.includes('/shop'))?window.location.origin:window.location.origin+'/shop';const sanitizedPathname=window.location.pathname.replace(/[<>"'&]/g,'');const sanitizedSearch=window.location.search.replace(/[<>"'&]/g,'');const cleanPathname=sanitizedPathname.startsWith('/shop')?sanitizedPathname.substring(5):sanitizedPathname;const newUrl=origin+'/boostmobile_sales_agent'+cleanPathname+sanitizedSearch;try{const urlObj=new URL(newUrl);if(!trustedDomains.some(domain=>urlObj.hostname===domain||urlObj.hostname.endsWith('.'+domain))){console.error('Redirect URL domain not trusted');return;}
6if(urlObj.protocol!=='https:'&&urlObj.protocol!=='http:'){console.error('Invalid protocol in redirect URL');return;}
7window.location.replace(newUrl);}catch(urlError){console.error('Invalid URL constructed:',urlError);}}catch(locationError){console.error('URL construction failed:',locationError);}}}catch(error){console.error('Sales agent redirect failed:',error);}})();

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.