fix: build failure when PDF viewer is disabled (#44964)
* fix: unused variable warning when the PDF viewer is disabled Co-authored-by: Charles Kerr <charles@charleskerr.com> * fix: unused function error when PDF viewer is disabled error: unused function ParseManifest [-Werror,-Wunused-function] Co-authored-by: Charles Kerr <charles@charleskerr.com> --------- Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Charles Kerr <charles@charleskerr.com>
This commit is contained in:
parent
2d45b7df34
commit
cfe549c739
1 changed files with 3 additions and 1 deletions
|
@ -87,6 +87,7 @@ void ElectronExtensionSystem::InitForRegularProfile(bool extensions_enabled) {
|
|||
management_policy_ = std::make_unique<ManagementPolicy>();
|
||||
}
|
||||
|
||||
#if BUILDFLAG(ENABLE_PDF_VIEWER)
|
||||
namespace {
|
||||
|
||||
std::unique_ptr<base::Value::Dict> ParseManifest(
|
||||
|
@ -103,10 +104,11 @@ std::unique_ptr<base::Value::Dict> ParseManifest(
|
|||
}
|
||||
|
||||
} // namespace
|
||||
#endif // if BUILDFLAG(ENABLE_PDF_VIEWER)
|
||||
|
||||
void ElectronExtensionSystem::LoadComponentExtensions() {
|
||||
std::string utf8_error;
|
||||
#if BUILDFLAG(ENABLE_PDF_VIEWER)
|
||||
std::string utf8_error;
|
||||
std::string pdf_manifest_string = pdf_extension_util::GetManifest();
|
||||
std::unique_ptr<base::Value::Dict> pdf_manifest =
|
||||
ParseManifest(pdf_manifest_string);
|
||||
|
|
Loading…
Reference in a new issue