1(function () { 2 var serviceWorkerHosts = { 3 'nf.video': true, 4 'www.nf.video': true, 5 'yhlxj.com': true, 6 'www.yhlxj.com': true, 7 'yhdev.nf.video': true, 8 'localhost': true, 9 '127.0.0.1': true, 10 }; 11 var currentScript = document.currentScript; 12 var baseUrl = new URL('./', currentScript.src); 13 var scope = baseUrl.pathname; 14 var serviceWorkerUrl = new URL('service-worker.js', baseUrl).pathname; 15 16 window.__galaxyServiceWorker = { 17 status: 'skipped', 18 }; 19 20 if ( 21 !serviceWorkerHosts[window.location.hostname] || 22 !('serviceWorker' in navigator) 23 ) { 24 return; 25 } 26 27 window.__galaxyServiceWorker.status = 'registering'; 28 29 navigator.serviceWorker 30 .register(serviceWorkerUrl, { 31 scope: scope, 32 updateViaCache: 'none', 33 }) 34 .then(function (registration) { 35 window.__galaxyServiceWorker = { 36 status: 'registered', 37 scope: registration.scope, 38 scriptURL: serviceWorkerUrl, 39 }; 40 }) 41 .catch(function (error) { 42 window.__galaxyServiceWorker = { 43 status: 'failed', 44 error: error && error.message ? error.message : String(error), 45 }; 46 console.warn('Service Worker registration failed:', error); 47 }); 48})();
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.