summaryrefslogtreecommitdiffstats
path: root/src/charts/line.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/charts/line.php')
-rw-r--r--src/charts/line.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/charts/line.php b/src/charts/line.php
index 1c8613b..ed342e8 100644
--- a/src/charts/line.php
+++ b/src/charts/line.php
@@ -350,7 +350,8 @@ class ezcGraphLineChart extends ezcGraphChart
}
// Store stacked value for next iteration
- $stacked[(int) ( $point->x * 10000 )][$point->y / abs( $point->y )] = $point;
+ $side = ( $point->y == 0 ? 1 : $point->y / abs( $point->y ) );
+ $stacked[(int) ( $point->x * 10000 )][$side] = $point;
$renderer->drawStackedBar(
$boundings,
OpenPOWER on IntegriCloud