blob: 80847357b5519769c47e2731817b3577375e2900 (
plain)
1
2
3
4
5
6
7
8
9
10
|
onconnect = function(e) {
try {
var port = e.ports[0]
var source = new EventSource("http://this is invalid/")
port.postMessage([false, 'no exception thrown'])
source.close()
} catch(e) {
port.postMessage([true, e.code])
}
}
|