You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by sh...@apache.org on 2020/10/09 11:18:20 UTC

[incubator-echarts] branch next updated: fix(pie): fix null access bug.

This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a commit to branch next
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git


The following commit(s) were added to refs/heads/next by this push:
     new 9cfbf0b  fix(pie): fix null access bug.
9cfbf0b is described below

commit 9cfbf0bcb0de72e004b115e1abd6f1364f417523
Author: pissang <bm...@gmail.com>
AuthorDate: Fri Oct 9 19:17:56 2020 +0800

    fix(pie): fix null access bug.
---
 src/chart/pie/PieView.ts | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/chart/pie/PieView.ts b/src/chart/pie/PieView.ts
index b758352..600361c 100644
--- a/src/chart/pie/PieView.ts
+++ b/src/chart/pie/PieView.ts
@@ -60,7 +60,10 @@ class PiePiece extends graphic.Sector {
         const itemModel = data.getItemModel<PieDataItemOption>(idx);
         const emphasisModel = itemModel.getModel('emphasis');
         const layout = data.getItemLayout(idx);
-        const sectorShape = extend(getSectorCornerRadius(itemModel.getModel('itemStyle'), layout), layout);
+        const sectorShape = extend(
+            getSectorCornerRadius(itemModel.getModel('itemStyle'), layout) || {},
+            layout
+        );
 
         if (firstCreate) {
             sector.setShape(sectorShape);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org