summaryrefslogtreecommitdiffstats
path: root/dom/indexedDB/IDBObjectStore.cpp
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2018-05-04 22:42:31 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-05-04 22:42:31 +0200
commit3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d (patch)
tree2ef4b78c728a2e1a323babc75205b19911a5ffc0 /dom/indexedDB/IDBObjectStore.cpp
parent175efcbab02bbfea84e565cdea9ee96d6436a08f (diff)
parent2860601772b392f3f6d2977269f11061f4e970ee (diff)
downloadUXP-3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d.tar
UXP-3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d.tar.gz
UXP-3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d.tar.lz
UXP-3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d.tar.xz
UXP-3b28e26d02106c31e3e2a03098ca24ea3f7e9f5d.zip
Merge branch 'intl-ICU-emoji-work'
Diffstat (limited to 'dom/indexedDB/IDBObjectStore.cpp')
-rw-r--r--dom/indexedDB/IDBObjectStore.cpp10
1 files changed, 0 insertions, 10 deletions
diff --git a/dom/indexedDB/IDBObjectStore.cpp b/dom/indexedDB/IDBObjectStore.cpp
index c9ab24970..cf62f49c3 100644
--- a/dom/indexedDB/IDBObjectStore.cpp
+++ b/dom/indexedDB/IDBObjectStore.cpp
@@ -1086,9 +1086,7 @@ IDBObjectStore::AppendIndexUpdateInfo(
{
nsresult rv;
-#ifdef ENABLE_INTL_API
const bool localeAware = !aLocale.IsEmpty();
-#endif
if (!aMultiEntry) {
Key key;
@@ -1106,14 +1104,12 @@ IDBObjectStore::AppendIndexUpdateInfo(
IndexUpdateInfo* updateInfo = aUpdateInfoArray.AppendElement();
updateInfo->indexId() = aIndexID;
updateInfo->value() = key;
-#ifdef ENABLE_INTL_API
if (localeAware) {
rv = key.ToLocaleBasedKey(updateInfo->localizedValue(), aLocale);
if (NS_WARN_IF(NS_FAILED(rv))) {
return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR;
}
}
-#endif
return NS_OK;
}
@@ -1153,14 +1149,12 @@ IDBObjectStore::AppendIndexUpdateInfo(
IndexUpdateInfo* updateInfo = aUpdateInfoArray.AppendElement();
updateInfo->indexId() = aIndexID;
updateInfo->value() = value;
-#ifdef ENABLE_INTL_API
if (localeAware) {
rv = value.ToLocaleBasedKey(updateInfo->localizedValue(), aLocale);
if (NS_WARN_IF(NS_FAILED(rv))) {
return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR;
}
}
-#endif
}
}
else {
@@ -1174,14 +1168,12 @@ IDBObjectStore::AppendIndexUpdateInfo(
IndexUpdateInfo* updateInfo = aUpdateInfoArray.AppendElement();
updateInfo->indexId() = aIndexID;
updateInfo->value() = value;
-#ifdef ENABLE_INTL_API
if (localeAware) {
rv = value.ToLocaleBasedKey(updateInfo->localizedValue(), aLocale);
if (NS_WARN_IF(NS_FAILED(rv))) {
return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR;
}
}
-#endif
}
return NS_OK;
@@ -2052,11 +2044,9 @@ IDBObjectStore::CreateIndex(const nsAString& aName,
// Valid locale names are always ASCII as per BCP-47.
nsCString locale = NS_LossyConvertUTF16toASCII(aOptionalParameters.mLocale);
bool autoLocale = locale.EqualsASCII("auto");
-#ifdef ENABLE_INTL_API
if (autoLocale) {
locale = IndexedDatabaseManager::GetLocale();
}
-#endif
IndexMetadata* metadata = indexes.AppendElement(
IndexMetadata(transaction->NextIndexId(), nsString(aName), keyPath,