From c0d60f17f706e27fee530aabea005d19183beac7 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Fri, 22 Dec 2017 10:09:02 -0800 Subject: [PATCH] Ensure language and country codes are not empty (#4492) --- runtime/runtime_controller.h | 4 ++-- shell/common/engine.cc | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/runtime/runtime_controller.h b/runtime/runtime_controller.h index d70bb177c8..c337c724b8 100644 --- a/runtime/runtime_controller.h +++ b/runtime/runtime_controller.h @@ -66,8 +66,8 @@ class RuntimeController : public WindowClient, public IsolateClient { void DidShutdownMainIsolate() override; RuntimeDelegate* client_; - std::string language_code_; - std::string country_code_; + std::string language_code_ = "en"; + std::string country_code_ = "US"; std::string user_settings_data_ = "{}"; bool semantics_enabled_ = false; std::unique_ptr dart_controller_; diff --git a/shell/common/engine.cc b/shell/common/engine.cc index 9f63afdf0e..f779143df4 100644 --- a/shell/common/engine.cc +++ b/shell/common/engine.cc @@ -118,6 +118,8 @@ Engine::Engine(PlatformView* platform_view) platform_view->GetVsyncWaiter(), this)), load_script_error_(tonic::kNoError), + language_code_("en"), + country_code_("US"), user_settings_data_("{}"), activity_running_(false), have_surface_(false), -- GitLab