Skip to content

Commit

Permalink
Cancel to check property value
Browse files Browse the repository at this point in the history
Fixed #22: Only check property, not limit property value to avoid side
effects
  • Loading branch information
Fengyuan Chen committed Dec 24, 2015
1 parent 1f9fe21 commit 533e708
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/methods.js
Original file line number Diff line number Diff line change
Expand Up @@ -601,12 +601,12 @@
cropBoxData.top = data.top;
}

if (isNumber(data.width) && data.width !== cropBoxData.width) {
if (isNumber(data.width)) {
widthChanged = true;
cropBoxData.width = data.width;
}

if (isNumber(data.height) && data.height !== cropBoxData.height) {
if (isNumber(data.height)) {
heightChanged = true;
cropBoxData.height = data.height;
}
Expand Down

0 comments on commit 533e708

Please sign in to comment.