Add `DetachedWindowAPI.close` calls
This commit is contained in:
parent
b667a68bd4
commit
5b282924ea
|
@ -241,11 +241,16 @@ export class ApRequestService {
|
|||
if (alternate) {
|
||||
const href = alternate.getAttribute('href');
|
||||
if (href) {
|
||||
// Since this early exits, we need to call DetachedWindowAPI.close
|
||||
await window.happyDOM.close();
|
||||
|
||||
return await this.signedGet(href, user, false);
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
// something went wrong parsing the HTML, ignore the whole thing
|
||||
} finally {
|
||||
await window.happyDOM.close();
|
||||
}
|
||||
}
|
||||
//#endregion
|
||||
|
|
Loading…
Reference in New Issue