Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1207)

Unified Diff: content/browser/indexed_db/indexed_db_factory.cc

Issue 119343004: IndexedDB: Simplify data loss code/message routing (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: git cl format Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/indexed_db/indexed_db_factory.cc
diff --git a/content/browser/indexed_db/indexed_db_factory.cc b/content/browser/indexed_db/indexed_db_factory.cc
index fb46b8f2c13db55737bc6e617d90f52415f67b13..4dce7b13bb9c243326d5ede8be22a71edbad5e5a 100644
--- a/content/browser/indexed_db/indexed_db_factory.cc
+++ b/content/browser/indexed_db/indexed_db_factory.cc
@@ -316,12 +316,11 @@ void IndexedDBFactory::Open(
database = it->second;
}
- database->OpenConnection(callbacks,
- database_callbacks,
- transaction_id,
- version,
- data_loss,
- data_loss_message);
+ if (data_loss != blink::WebIDBDataLossNone)
+ callbacks->OnDataLoss(data_loss, data_loss_message);
+
+ database->OpenConnection(
+ callbacks, database_callbacks, transaction_id, version);
if (!was_open && database->ConnectionCount() > 0)
database_map_[unique_identifier] = database;
« no previous file with comments | « content/browser/indexed_db/indexed_db_database.cc ('k') | content/browser/indexed_db/indexed_db_factory_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698