From ecc36ec3cc3d0de2afb631ef3e26fc48f733d9a6 Mon Sep 17 00:00:00 2001 From: sapics Date: Wed, 20 Jan 2016 14:35:28 +0900 Subject: [PATCH] Remove unused variable in group._draw --- src/item/Group.js | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/src/item/Group.js b/src/item/Group.js index 7ec179ba..650b0ef6 100644 --- a/src/item/Group.js +++ b/src/item/Group.js @@ -169,8 +169,7 @@ var Group = Item.extend(/** @lends Group# */{ _draw: function(ctx, param) { var clip = param.clip, - clipItem = !clip && this._getClipItem(), - draw = true; + clipItem = !clip && this._getClipItem(); param = param.extend({ clipItem: clipItem, clip: false }); if (clip) { // If told to clip with a group, we start our own path and draw each @@ -180,13 +179,11 @@ var Group = Item.extend(/** @lends Group# */{ } else if (clipItem) { clipItem.draw(ctx, param.extend({ clip: true })); } - if (draw) { - var children = this._children; - for (var i = 0, l = children.length; i < l; i++) { - var item = children[i]; - if (item !== clipItem) - item.draw(ctx, param); - } + var children = this._children; + for (var i = 0, l = children.length; i < l; i++) { + var item = children[i]; + if (item !== clipItem) + item.draw(ctx, param); } } });