fx-compat: Fix error passing cookieSandbox to Zotero.HTTP.request()

https://groups.google.com/g/zotero-dev/c/UgP_kZvrEjA/m/KjimYREGAgAJ

getInterface() seems to exist on XHR and nsIWBP without QIing to
nsIInterfaceRequestor, and XHR no longer has QueryInterface().
This commit is contained in:
Dan Stillman 2023-07-17 06:39:25 -04:00
parent 65fe50d11f
commit c425f71ac4

View file

@ -164,7 +164,7 @@ Zotero.CookieSandbox.prototype = {
* @param {nsIInterfaceRequestor} ir
*/
"attachToInterfaceRequestor": function(ir) {
Zotero.CookieSandbox.Observer.trackedInterfaceRequestors.push(Cu.getWeakReference(ir.QueryInterface(Ci.nsIInterfaceRequestor)));
Zotero.CookieSandbox.Observer.trackedInterfaceRequestors.push(Cu.getWeakReference(ir));
Zotero.CookieSandbox.Observer.trackedInterfaceRequestorSandboxes.push(this);
},