Bug 1959768 - avoid sending empty BHR pings, r=chutten.

Differential Revision: https://phabricator.services.mozilla.com/D245243
This commit is contained in:
Florian Quèze
2025-04-11 20:52:47 +00:00
parent f42fc46fc0
commit c9c4e7a888

View File

@@ -125,7 +125,8 @@ BHRTelemetryService.prototype = Object.freeze({
// errors) while avoiding timeouts caused by invoking `pingsender` during
// testing.
if (
Services.prefs.getBoolPref("toolkit.telemetry.bhrPing.enabled", false)
Services.prefs.getBoolPref("toolkit.telemetry.bhrPing.enabled", false) &&
this.payload.hangs.length
) {
this.payload.timeSinceLastPing = new Date() - this.startTime;
lazy.TelemetryController.submitExternalPing("bhr", this.payload, {