[Profiling] fixing flamegraph color (#160494)

Before:
<img width="1170" alt="Screenshot 2023-06-26 at 9 57 58 AM"
src="44993c9e-7d13-4b41-ba1c-d85c742a81f9">

After:
<img width="1076" alt="Screenshot 2023-06-26 at 9 58 29 AM"
src="91c94fd4-773b-4fab-80ea-2c45f64ae2ad">
This commit is contained in:
Cauê Marcondes 2023-06-27 08:53:04 +01:00 committed by GitHub
parent ac288a106c
commit 5ac84d1f72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -101,7 +101,7 @@ export function createCalleeTree(
// e.g. when stopping the host agent or on network errors.
const stackTrace = stackTraces.get(stackTraceID) ?? emptyStackTrace;
const lenStackTrace = stackTrace.FrameIDs.length;
const samples = (events.get(stackTraceID) ?? 0) * scalingFactor;
const samples = Math.floor((events.get(stackTraceID) ?? 0) * scalingFactor);
let currentNode = 0;