aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/script_runtime.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/script_runtime.rs')
-rw-r--r--components/script/script_runtime.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/components/script/script_runtime.rs b/components/script/script_runtime.rs
index 18138dcc2b0..865382f091f 100644
--- a/components/script/script_runtime.rs
+++ b/components/script/script_runtime.rs
@@ -145,7 +145,10 @@ pub struct Runtime(RustRuntime);
impl Drop for Runtime {
fn drop(&mut self) {
- THREAD_ACTIVE.with(|t| t.set(false));
+ THREAD_ACTIVE.with(|t| {
+ LiveDOMReferences::destruct();
+ t.set(false);
+ });
}
}