From 1df2b37bc5b3f66ed38d53d4a12b96f1d3a4fb9a Mon Sep 17 00:00:00 2001 From: Tanner Linsley Date: Thu, 30 Apr 2015 15:49:52 -0600 Subject: [PATCH] Only draw positive radius arcs Fixes #592 --- src/Chart.Core.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Chart.Core.js b/src/Chart.Core.js index f6a6995be..2e26a8abb 100755 --- a/src/Chart.Core.js +++ b/src/Chart.Core.js @@ -1293,9 +1293,9 @@ ctx.beginPath(); - ctx.arc(this.x, this.y, this.outerRadius, this.startAngle, this.endAngle); + ctx.arc(this.x, this.y, this.outerRadius < 0 ? 0 : this.outerRadius, this.startAngle, this.endAngle); - ctx.arc(this.x, this.y, this.innerRadius, this.endAngle, this.startAngle, true); + ctx.arc(this.x, this.y, this.innerRadius < 0 ? 0 : this.innerRadius, this.endAngle, this.startAngle, true); ctx.closePath(); ctx.strokeStyle = this.strokeColor;