Bug 1517089 - Part 15: Remove a hack for JetPack and DevTools fron QuotaManager:GetInfoFromPrincipal; r=asuth

The special case is now handled in GetSpecialBaseDomain in ContentPrincipal.cpp

Differential Revision: https://phabricator.services.mozilla.com/D19212
This commit is contained in:
Jan Varga 2019-02-08 21:02:19 +01:00
Родитель f150c82b06
Коммит b359db62fd
1 изменённых файлов: 3 добавлений и 20 удалений

Просмотреть файл

@ -5494,28 +5494,11 @@ nsresult QuotaManager::GetInfoFromPrincipal(nsIPrincipal* aPrincipal,
if (aGroup) {
nsCString baseDomain;
rv = aPrincipal->GetBaseDomain(baseDomain);
if (NS_FAILED(rv)) {
// A hack for JetPack.
nsCOMPtr<nsIURI> uri;
rv = aPrincipal->GetURI(getter_AddRefs(uri));
NS_ENSURE_SUCCESS(rv, rv);
bool isIndexedDBURI = false;
rv = uri->SchemeIs("indexedDB", &isIndexedDBURI);
NS_ENSURE_SUCCESS(rv, rv);
if (isIndexedDBURI) {
rv = NS_OK;
}
}
NS_ENSURE_SUCCESS(rv, rv);
if (baseDomain.IsEmpty()) {
aGroup->Assign(origin);
} else {
aGroup->Assign(baseDomain + suffix);
}
MOZ_ASSERT(!baseDomain.IsEmpty());
aGroup->Assign(baseDomain + suffix);
}
if (aOrigin) {