PageSourceSearch

https://bilinord.no/corepublish/cplib-common/WebsocketManager_v1.0.0.js?appver=b397dd99f6

js bilinord.no collected 2026-10-09 03:04:32 UTC 2,159 bytes, 1 lines download raw bytes

1function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,_toPropertyKey(o.key),o)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return"symbol"==_typeof(t)?t:t+""}function _toPrimitive(e,t){if("object"!=_typeof(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=_typeof(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}var WebsocketManager=function(){function e(){_classCallCheck(this,e)}return _createClass(e,[{key:"getChannelPrefix",value:function(){var e,t,n=(null===(e=window.corepublish)||void 0===e?void 0:e.systemId)||"",o=(null===(t=window.corepublish)||void 0===t?void 0:t.domainId)||"";return n&&o||console.warn("WebsocketManager: Missing systemId or domainId in window.corepublish"),"".concat(n,".").concat(o,".")}},{key:"isAvailable",value:function(){var e,t;return null!==(e=null===(t=window.corepublish)||void 0===t?void 0:t.websocketActive)&&void 0!==e&&e&&void 0!==window.Echo}},{key:"subscribePrivate",value:function(e){if(!this.isAvailable())return null;var t=this.getChannelPrefix()+e;return window.Echo.private(t)}},{key:"subscribePublic",value:function(e){if(!this.isAvailable())return null;var t=this.getChannelPrefix()+e;return window.Echo.channel(t)}},{key:"unsubscribe",value:function(e){if(this.isAvailable()){var t=this.getChannelPrefix()+e;window.Echo.leave(t)}}}]),e}();window.WebsocketManager=new WebsocketManager,"undefined"!=typeof module&&(module.exports=WebsocketManager);

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.