Skip to content

Commit

Permalink
revert Object.keys
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaMan123 committed May 19, 2023
1 parent c58c7a9 commit 4e254cb
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/shapes/Object/InteractiveObject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,11 +191,10 @@ export class InteractiveFabricObject<

this.__corner = undefined;
// had to keep the reverse loop because was breaking tests
const controlKeys = Object.keys(this.oCoords);
const controlKeys = Object.entries(this.oCoords);
for (let i = controlKeys.length - 1; i >= 0; i--) {
const key = controlKeys[i];
const [key, corner] = controlKeys[i];
if (this.controls[key].shouldActivate(key, this)) {
const corner = this.oCoords[key];
const lines = this._getImageLines(
forTouch ? corner.touchCorner : corner.corner
);
Expand Down

0 comments on commit 4e254cb

Please sign in to comment.