| Index: components/history/core/browser/history_backend.cc
|
| diff --git a/components/history/core/browser/history_backend.cc b/components/history/core/browser/history_backend.cc
|
| index 1565486d534978c740ea47500ad2129eb2daae66..08cacf54212abaa3b3639e655f75878563e0b986 100644
|
| --- a/components/history/core/browser/history_backend.cc
|
| +++ b/components/history/core/browser/history_backend.cc
|
| @@ -1168,11 +1168,16 @@ void HistoryBackend::QueryDownloads(std::vector<DownloadRow>* rows) {
|
| }
|
|
|
| // Update a particular download entry.
|
| -void HistoryBackend::UpdateDownload(const DownloadRow& data) {
|
| +void HistoryBackend::UpdateDownload(
|
| + const DownloadRow& data,
|
| + bool should_commit_immediately) {
|
| if (!db_)
|
| return;
|
| db_->UpdateDownload(data);
|
| - ScheduleCommit();
|
| + if (should_commit_immediately)
|
| + Commit();
|
| + else
|
| + ScheduleCommit();
|
| }
|
|
|
| bool HistoryBackend::CreateDownload(const DownloadRow& history_info) {
|
|
|