Bug 1287091 - part 2 - ContextualIdentityService must store telemetry data in a separate array, r=Gijs

This commit is contained in:
Andrea Marchesini 2016-07-23 08:57:53 +02:00
Родитель 6871885a3e
Коммит 173c3cdfdd
1 изменённых файлов: 4 добавлений и 8 удалений

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

@ -41,7 +41,6 @@ this.ContextualIdentityService = {
color: "#00a7e0",
label: "userContextPersonal.label",
accessKey: "userContextPersonal.accesskey",
alreadyOpened: false,
telemetryId: 1,
},
{ userContextId: 2,
@ -50,7 +49,6 @@ this.ContextualIdentityService = {
color: "#f89c24",
label: "userContextWork.label",
accessKey: "userContextWork.accesskey",
alreadyOpened: false,
telemetryId: 2,
},
{ userContextId: 3,
@ -59,7 +57,6 @@ this.ContextualIdentityService = {
color: "#7dc14c",
label: "userContextBanking.label",
accessKey: "userContextBanking.accesskey",
alreadyOpened: false,
telemetryId: 3,
},
{ userContextId: 4,
@ -68,7 +65,6 @@ this.ContextualIdentityService = {
color: "#ee5195",
label: "userContextShopping.label",
accessKey: "userContextShopping.accesskey",
alreadyOpened: false,
telemetryId: 4,
},
{ userContextId: Math.pow(2, 31) - 1,
@ -76,11 +72,11 @@ this.ContextualIdentityService = {
icon: "",
color: "",
label: "userContextIdInternal.thumbnail",
accessKey: "",
alreadyOpened: false },
accessKey: "" },
],
_identities: null,
_openedIdentities: new Set(),
_path: null,
_dataReady: false,
@ -219,8 +215,8 @@ this.ContextualIdentityService = {
return;
}
if (!identity.alreadyOpened) {
identity.alreadyOpened = true;
if (this._openedIdentities.has(userContextId)) {
this._openedIdentities.add(userContextId);
Services.telemetry.getHistogramById("UNIQUE_CONTAINERS_OPENED").add(1);
}