From e6c479e956d8affc3dff504e14050bdb82fad5ab Mon Sep 17 00:00:00 2001 From: Dunedan Date: Sat, 14 Jun 2025 17:18:08 +0200 Subject: [PATCH] Show report statistics for single reports as well --- source/tools/profiler2/profiler2.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/source/tools/profiler2/profiler2.js b/source/tools/profiler2/profiler2.js index cb2b192d3d..1d96e8d5dc 100644 --- a/source/tools/profiler2/profiler2.js +++ b/source/tools/profiler2/profiler2.js @@ -283,15 +283,15 @@ function compare_reports() const section = document.getElementById("comparison"); section.innerHTML = "

Report Comparison

"; - if (g_reports.length < 2) + if (g_active_elements.length < 1) { - section.innerHTML += "

Too few reports loaded

"; + section.innerHTML += "

Select an element to show statistics

"; return; } - if (g_active_elements.length != 1) + if (g_active_elements.length > 1) { - section.innerHTML += "

Too many of too few elements selected

"; + section.innerHTML += "

Too many elements selected

"; return; }