Skip to content

Commit f1fdc8d

Browse files
committed
height must be at least 1
1 parent e80aed9 commit f1fdc8d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Linechart.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ private function prepareData(): void
271271

272272
$this->range = max(1, abs($max - $min));
273273

274-
$height = (int) ($this->getSettings()->getHeight() ?? $this->range);
274+
$height = max(1, (int) ($this->getSettings()->getHeight() ?? $this->range));
275275
$this->ratio = $height / $this->range;
276276

277277
$this->min2 = $min * $this->ratio;

0 commit comments

Comments
 (0)