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

Unified Diff: Source/modules/indexeddb/IDBObjectStore.cpp

Issue 18548003: Rename ExceptionCode constants to use the names in the spec (2/3) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 6 months 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
« no previous file with comments | « Source/modules/indexeddb/IDBIndex.cpp ('k') | Source/modules/indexeddb/IDBRequest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/indexeddb/IDBObjectStore.cpp
diff --git a/Source/modules/indexeddb/IDBObjectStore.cpp b/Source/modules/indexeddb/IDBObjectStore.cpp
index 1388897ee60f291ed1bfdb53015a33afbf5095e7..117dab78aeca995bf03294b3bb42647a5cebef59 100644
--- a/Source/modules/indexeddb/IDBObjectStore.cpp
+++ b/Source/modules/indexeddb/IDBObjectStore.cpp
@@ -73,7 +73,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::get(ScriptExecutionContext* context, Pass
{
IDB_TRACE("IDBObjectStore::get");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!keyRange) {
@@ -144,7 +144,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::put(IDBDatabaseBackendInterface::PutMode
{
RefPtr<IDBKey> key = prpKey;
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
@@ -230,7 +230,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::deleteFunction(ScriptExecutionContext* co
{
IDB_TRACE("IDBObjectStore::delete");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
@@ -263,7 +263,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::clear(ScriptExecutionContext* context, Ex
{
IDB_TRACE("IDBObjectStore::clear");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
@@ -365,7 +365,7 @@ PassRefPtr<IDBIndex> IDBObjectStore::createIndex(ScriptExecutionContext* context
{
IDB_TRACE("IDBObjectStore::createIndex");
if (!m_transaction->isVersionChange() || isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
@@ -373,7 +373,7 @@ PassRefPtr<IDBIndex> IDBObjectStore::createIndex(ScriptExecutionContext* context
return 0;
}
if (!keyPath.isValid()) {
- ec = SYNTAX_ERR;
+ ec = SyntaxError;
return 0;
}
if (name.isNull()) {
@@ -386,7 +386,7 @@ PassRefPtr<IDBIndex> IDBObjectStore::createIndex(ScriptExecutionContext* context
}
if (keyPath.type() == IDBKeyPath::ArrayType && multiEntry) {
- ec = INVALID_ACCESS_ERR;
+ ec = InvalidAccessError;
return 0;
}
@@ -422,11 +422,11 @@ PassRefPtr<IDBIndex> IDBObjectStore::index(const String& name, ExceptionCode& ec
{
IDB_TRACE("IDBObjectStore::index");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (m_transaction->isFinished()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
@@ -460,7 +460,7 @@ void IDBObjectStore::deleteIndex(const String& name, ExceptionCode& ec)
{
IDB_TRACE("IDBObjectStore::deleteIndex");
if (!m_transaction->isVersionChange() || isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return;
}
if (!m_transaction->isActive()) {
@@ -489,7 +489,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::openCursor(ScriptExecutionContext* contex
{
IDB_TRACE("IDBObjectStore::openCursor");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
@@ -519,7 +519,7 @@ PassRefPtr<IDBRequest> IDBObjectStore::count(ScriptExecutionContext* context, Pa
{
IDB_TRACE("IDBObjectStore::count");
if (isDeleted()) {
- ec = INVALID_STATE_ERR;
+ ec = InvalidStateError;
return 0;
}
if (!m_transaction->isActive()) {
« no previous file with comments | « Source/modules/indexeddb/IDBIndex.cpp ('k') | Source/modules/indexeddb/IDBRequest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698