From dfc265d736053094f355d94f4da2f20036c2ddd8 Mon Sep 17 00:00:00 2001 From: jrfnl Date: Tue, 4 Feb 2020 16:18:53 +0100 Subject: [PATCH] Report/Info: fix "undefined variable" error. This partially reverts the change made to this particular file in e9ebf5253a3e6dd3cc4b584ce54b1f4c34fcb1f3 The `floor( $countWidth / 3)` was causing an _undefined variable_ notice. --- src/Reports/Info.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Reports/Info.php b/src/Reports/Info.php index 7092e78ce4..5028d37199 100644 --- a/src/Reports/Info.php +++ b/src/Reports/Info.php @@ -116,7 +116,9 @@ public function generate( // Length of the total string, plus however many // thousands separators there are. - $countWidth = (strlen($totalCount) + floor($countWidth / 3)); + $countWidth = strlen($totalCount); + $nrOfThousandSeps = floor($countWidth / 3); + $countWidth += $nrOfThousandSeps; // Account for 'total' line. $valueWidth = max(5, $valueWidth);