diff --git a/atom/browser/common_web_contents_delegate.cc b/atom/browser/common_web_contents_delegate.cc index 53503d56383e..98b1a0177553 100644 --- a/atom/browser/common_web_contents_delegate.cc +++ b/atom/browser/common_web_contents_delegate.cc @@ -163,7 +163,7 @@ void CommonWebContentsDelegate::InitWithWebContents( // Determien whether the WebContents is offscreen. auto* web_preferences = WebContentsPreferences::From(web_contents); offscreen_ = - !web_preferences || web_preferences->IsEnabled(options::kOffscreen); + web_preferences && web_preferences->IsEnabled(options::kOffscreen); // Create InspectableWebContents. web_contents_.reset(brightray::InspectableWebContents::Create(