Skip to content

Commit

Permalink
refactor(src): prevent error if actionName is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
nichollascarter committed Dec 14, 2021
1 parent 080cf48 commit 2f5b65e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/core/transform/Transformable.js
Original file line number Diff line number Diff line change
Expand Up @@ -703,7 +703,7 @@ export default class Transformable extends SubjectModel {

if (!isTarget) return;

const { actionName } = [
const { actionName = E_DRAG } = [
{
actionName: E_RESIZE,
condition: doResize
Expand All @@ -720,7 +720,7 @@ export default class Transformable extends SubjectModel {
actionName: E_SET_POINT,
condition: doSetCenter
}
].find((({ condition }) => condition));
].find((({ condition }) => condition)) || {};


storage.doResize = false;
Expand Down

0 comments on commit 2f5b65e

Please sign in to comment.