Skip to content

Commit

Permalink
Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
ehmicky committed Sep 5, 2021
1 parent de18598 commit 9478008
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/report/reporters/boxplot/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,13 @@ const LABELS_HEIGHT = 1
// Retrieve the width of those blocks
const getMinMaxBlockWidth = function (combinations, statName) {
return Math.max(
...combinations.map((combination) =>
getSingleMinMaxWidth(combination, statName),
...combinations.map(({ quantiles }) =>
getSingleMinMaxWidth(quantiles, statName),
),
)
}

const getSingleMinMaxWidth = function ({ quantiles }, statName) {
const getSingleMinMaxWidth = function (quantiles, statName) {
return quantiles === undefined
? 0
: addPadding(quantiles[statName].prettyPadded).length
Expand Down

0 comments on commit 9478008

Please sign in to comment.