Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaMan123 committed Jul 1, 2021
1 parent 99ff886 commit 97ee528
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/brushes/base_brush.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,9 @@ fabric.BaseBrush = fabric.util.createClass(/** @lends fabric.BaseBrush.prototype
* @param {fabric.Object} result
*/
_addClipPathToResult: function (result) {
if (!this.clipPath) return;
if (!this.clipPath) {
return;
}
this.clipPath.clone(function (clipPath) {
var desiredTransform = fabric.util.multiplyTransformMatrices(
fabric.util.invertTransform(result.calcTransformMatrix()),
Expand Down
2 changes: 1 addition & 1 deletion src/brushes/spray_brush.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ fabric.SprayBrush = fabric.util.createClass( fabric.BaseBrush, /** @lends fabric
var group = new fabric.Group(rects);
this.shadow && group.set('shadow', new fabric.Shadow(this.shadow));
this._addClipPathToResult(group);

this.canvas.fire('before:path:created', { path: group });
this.canvas.add(group);
this.canvas.fire('path:created', { path: group });
Expand Down

0 comments on commit 97ee528

Please sign in to comment.