diff --git a/atom/browser/api/atom_api_protocol.cc b/atom/browser/api/atom_api_protocol.cc index 5e1f991ad8dc..9c171abd54e0 100644 --- a/atom/browser/api/atom_api_protocol.cc +++ b/atom/browser/api/atom_api_protocol.cc @@ -50,7 +50,7 @@ void RegisterStandardSchemes(const std::vector& schemes, // Dynamically register the schemes. auto* policy = content::ChildProcessSecurityPolicy::GetInstance(); for (const std::string& scheme : schemes) { - url::AddStandardScheme(scheme.c_str(), url::SCHEME_WITHOUT_PORT); + url::AddStandardScheme(scheme.c_str(), url::SCHEME_WITH_HOST); if (secure) { url::AddSecureScheme(scheme.c_str()); } diff --git a/atom/renderer/renderer_client_base.cc b/atom/renderer/renderer_client_base.cc index 07e52f5a7475..ae455f04b56e 100644 --- a/atom/renderer/renderer_client_base.cc +++ b/atom/renderer/renderer_client_base.cc @@ -78,7 +78,7 @@ RendererClientBase::RendererClientBase() { std::vector standard_schemes_list = ParseSchemesCLISwitch(command_line, switches::kStandardSchemes); for (const std::string& scheme : standard_schemes_list) - url::AddStandardScheme(scheme.c_str(), url::SCHEME_WITHOUT_PORT); + url::AddStandardScheme(scheme.c_str(), url::SCHEME_WITH_HOST); isolated_world_ = base::CommandLine::ForCurrentProcess()->HasSwitch( switches::kContextIsolation); // We rely on the unique process host id which is notified to the