chore: add DCHECK to ensure extension_system() is not used for in-memory sessions (#23475)

This commit is contained in:
Samuel Attard 2020-05-11 11:13:30 -07:00 committed by GitHub
parent ce4d95b16a
commit 4af5c55c8d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -139,9 +139,10 @@ class ElectronBrowserContext
}
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
// Guard usages of extension_system() with !IsOffTheRecord()
// There is no extension system for in-memory sessions
extensions::ElectronExtensionSystem* extension_system() {
// Guard usages of extension_system() with !IsOffTheRecord()
// There is no extension system for in-memory sessions
DCHECK(!IsOffTheRecord());
return extension_system_;
}
#endif