mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
chore: synchronously destroy WebContents on event prevented (#26418)
Co-authored-by: Jeremy Rose <jeremya@chromium.org>
This commit is contained in:
@@ -823,8 +823,7 @@ void WebContents::AddNewContents(
|
||||
initial_rect.x(), initial_rect.y(), initial_rect.width(),
|
||||
initial_rect.height(), tracker->url, tracker->frame_name,
|
||||
tracker->referrer, tracker->raw_features, tracker->body)) {
|
||||
// TODO(zcbenz): Can we make this sync?
|
||||
api_web_contents->DestroyWebContents(true /* async */);
|
||||
api_web_contents->DestroyWebContents(false /* async */);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user