From 6ee740ea299f38da59cce3e8a2906fbbf7d3d33b Mon Sep 17 00:00:00 2001 From: Paul Irish Date: Thu, 21 Oct 2021 12:54:26 -0700 Subject: [PATCH] [Lighthouse] Remove DOM check when adding view trace button MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Lighthouse's `addButton` handles this for us–and besides, the DOM has changed and this check is no longer valid. Bug: 1262253 Change-Id: I63a1442a07fb139a6a7d760f76d57e546b36e0f7 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3237595 Reviewed-by: Connor Clark Commit-Queue: Connor Clark Auto-Submit: Paul Irish --- front_end/panels/lighthouse/LighthouseReportRenderer.ts | 5 ----- 1 file changed, 5 deletions(-) diff --git a/front_end/panels/lighthouse/LighthouseReportRenderer.ts b/front_end/panels/lighthouse/LighthouseReportRenderer.ts index 801314189e..4f19cb14cc 100644 --- a/front_end/panels/lighthouse/LighthouseReportRenderer.ts +++ b/front_end/panels/lighthouse/LighthouseReportRenderer.ts @@ -51,11 +51,6 @@ export class LighthouseReportRenderer extends LighthouseReport.ReportRenderer { if (!container) { return; } - const disclaimerEl = container.querySelector('.lh-metrics__disclaimer'); - // If it was a PWA-only run, we'd have a trace but no perf category to add the button to - if (!disclaimerEl) { - return; - } const defaultPassTrace = artifacts.traces.defaultPass; const text = simulated ? i18nString(UIStrings.viewOriginalTrace) : i18nString(UIStrings.viewTrace);