| Index: chrome/browser/ui/webui/history_ui.cc
|
| diff --git a/chrome/browser/ui/webui/history_ui.cc b/chrome/browser/ui/webui/history_ui.cc
|
| index af647cee1d892e757c1c8f857a9cdca3b71c29c7..7d800dd5a388f8f74cdb77223f18153021c78f51 100644
|
| --- a/chrome/browser/ui/webui/history_ui.cc
|
| +++ b/chrome/browser/ui/webui/history_ui.cc
|
| @@ -176,11 +176,14 @@ HistoryUI::HistoryUI(content::WebUI* web_ui) : WebUIController(web_ui) {
|
| web_ui->AddMessageHandler(new BrowsingHistoryHandler());
|
| web_ui->AddMessageHandler(new MetricsHandler());
|
|
|
| + Profile* profile = Profile::FromWebUI(web_ui);
|
| + content::WebUIDataSource* data_source = CreateHistoryUIHTMLSource(profile);
|
| +
|
| // On mobile we deal with foreign sessions differently.
|
| #if !defined(OS_ANDROID)
|
| if (search::IsInstantExtendedAPIEnabled()) {
|
| web_ui->AddMessageHandler(new browser_sync::ForeignSessionHandler());
|
| - web_ui->AddMessageHandler(new HistoryLoginHandler());
|
| + web_ui->AddMessageHandler(new HistoryLoginHandler(data_source));
|
| }
|
| #endif
|
|
|
| @@ -199,8 +202,8 @@ HistoryUI::HistoryUI(content::WebUI* web_ui) : WebUIController(web_ui) {
|
| }
|
|
|
| // Set up the chrome://history-frame/ source.
|
| - Profile* profile = Profile::FromWebUI(web_ui);
|
| - content::WebUIDataSource::Add(profile, CreateHistoryUIHTMLSource(profile));
|
| + content::WebUIDataSource::Add(profile, data_source);
|
| +
|
| }
|
|
|
| HistoryUI::~HistoryUI() {}
|
|
|