Bug 875712 - When a system update removes a system app, delete the app data from the registry after deleting the private data, not before, r=fabrice

--HG--
extra : rebase_source : a01e8a07760eab05504395c897a49482384f2af4
This commit is contained in:
Antonio M. Amaya 2013-05-24 12:07:10 +02:00
Родитель 6e041b2bae
Коммит 9e1089ec99
1 изменённых файлов: 1 добавлений и 1 удалений

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

@ -384,7 +384,6 @@ this.DOMApplicationRegistry = {
for (let id in this.webapps) { for (let id in this.webapps) {
if (id in aData || this.webapps[id].removable) if (id in aData || this.webapps[id].removable)
continue; continue;
delete this.webapps[id];
// Remove the permissions, cookies and private data for this app. // Remove the permissions, cookies and private data for this app.
let localId = this.webapps[id].localId; let localId = this.webapps[id].localId;
let permMgr = Cc["@mozilla.org/permissionmanager;1"] let permMgr = Cc["@mozilla.org/permissionmanager;1"]
@ -392,6 +391,7 @@ this.DOMApplicationRegistry = {
permMgr.RemovePermissionsForApp(localId, false); permMgr.RemovePermissionsForApp(localId, false);
Services.cookies.removeCookiesForApp(localId, false); Services.cookies.removeCookiesForApp(localId, false);
this._clearPrivateData(localId, false); this._clearPrivateData(localId, false);
delete this.webapps[id];
} }
let appDir = FileUtils.getDir("coreAppsDir", ["webapps"], false); let appDir = FileUtils.getDir("coreAppsDir", ["webapps"], false);