tracker issue : CF-4198789

select a category, or use search below
(searches all categories and all time range)

onerror failing

| View in Tracker

Status/Resolution/Reason: Closed/Withdrawn/PRNeedInfo

Reporter/Name(from Bugbase): Aaron Shurmer / Aaron Shurmer ()

Created: 05/29/2017

Components: Web Socket

Versions: 2016

Failure Type: Others

Found In Build/Fixed In Build: latest patched /

Priority/Frequency: Normal /

Locale/System: / Win All

Vote Count: 0

Problem Description:
javascript error being thrown on chrome - latest version. stops JS getting to onError provided in cfwebsocket tag.

Uncaught TypeError: Cannot set property 'readyState' of undefined
    at WebSocket.wsConnection.onerror (cfwebsocketCore.js:54)

Steps to Reproduce:
turn web socket server to proxy mode, so it fails, then hit a web socket.

the following code fails in chrome, i'm gussing you need a closure or something to keep reference.
code failing: this.wsConnection.readyState=cf_ws.CLOSED;
fails as this.wsConnection not defined.


Actual Result:

Expected Result:

Any Workarounds:



this fixes your closure, might need doing in lots more place though. thisObj = this; this.wsConnection.onerror=function(_4a7){ thisObj.wsConnection.readyState=cf_ws.CLOSED; if(_4a1.onError){ _4a1.onError(null,_4a2); } }; }
Comment by Aaron S.
644 | May 29, 2017 12:53:50 AM GMT
Hi Aaron, Can you please share your test case where you hit this issue? We are unable to repro this in our end even with latest chrome. Thanks, Kailash
Comment by Kailash B.
645 | May 30, 2017 06:15:14 AM GMT
Unable to repro this case. Will reopen once user comes back with a repro case.
Comment by Kailash B.
646 | September 11, 2017 04:54:37 AM GMT