-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Steps to reproduce:
1.Open http://astrojs.github.io/sampjs/examples/monitor.html and connect it to hub
2.Add to page HTML with devtools or script this link
<a href="javascript:void(document.location='http://aladin.u-strasbg.fr/java/nph-aladin.pl?frame=get&id=AladinBeta.jnlp');">launch Aladin</a>
3.Click on added link
Result: Aladin is started, but client tracker does not show it in list.
Cause: Request 'pullCallbacks' was cancelled by browser. but samp XmlRpcClient does not have 'onabort' handler and can't recover.
I suggest to patch it like this, but not sure about different implementations of Xhr used in samp.js
diff --git a/samp.js b/samp.js
index a621029..33b0aa9 100644
--- a/samp.js
+++ b/samp.js
@@ -591,6 +591,9 @@ var samp = (function() {
errHandler(event);
}
};
+ xhr.xhr.onabort = function(event) {
+ xhr.onerror(event);
+ };
xhr.send(req.toXml());
return xhr;
})(this);
Metadata
Metadata
Assignees
Labels
No labels