Merge f9ca780dd3
into a44bf21582
This commit is contained in:
commit
345b4b5c50
1 changed files with 8 additions and 7 deletions
|
@ -6,6 +6,9 @@ const { storage } = require('sdk/simple-storage');
|
|||
const {
|
||||
TelemetryController
|
||||
} = require('resource://gre/modules/TelemetryController.jsm');
|
||||
const {
|
||||
TelemetryEnvironment
|
||||
} = require ('resource://gre/modules/TelemetryEnvironment.jsm');
|
||||
const { Request } = require('sdk/request');
|
||||
|
||||
|
||||
|
@ -44,9 +47,7 @@ function experimentPing(event) {
|
|||
});
|
||||
|
||||
// TODO: DRY up this ping centre code here and in lib/Telemetry.
|
||||
const pcPing = TelemetryController.getCurrentPingData();
|
||||
pcPing.type = 'testpilot';
|
||||
pcPing.payload = payload;
|
||||
const environment = TelemetryEnvironment.currentEnvironment;
|
||||
const pcPayload = {
|
||||
// 'method' is used by testpilot-metrics library.
|
||||
// 'event' was used before that library existed.
|
||||
|
@ -54,10 +55,10 @@ function experimentPing(event) {
|
|||
client_time: makeTimestamp(parsed.timestamp || timestamp),
|
||||
addon_id: subject,
|
||||
addon_version: addon.version,
|
||||
firefox_version: pcPing.environment.build.version,
|
||||
os_name: pcPing.environment.system.os.name,
|
||||
os_version: pcPing.environment.system.os.version,
|
||||
locale: pcPing.environment.settings.locale,
|
||||
firefox_version: environment.build.version,
|
||||
os_name: environment.system.os.name,
|
||||
os_version: environment.system.os.version,
|
||||
locale: environment.settings.locale,
|
||||
// Note: these two keys are normally inserted by the ping-centre client.
|
||||
client_id: ClientID.getCachedClientID(),
|
||||
topic: 'testpilot'
|
||||
|
|
Loading…
Add table
Reference in a new issue