Skip to content

Commit

Permalink
fix: added onchange check
Browse files Browse the repository at this point in the history
  • Loading branch information
rupato-deriv committed Dec 12, 2024
1 parent 9f1f0f9 commit 2d3a483
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ Blockly.Blocks.accumulator_take_profit = {
}
if (
(event.type === Blockly.Events.BLOCK_CREATE && event.ids.includes(this.id)) ||
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart)
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart) ||
(event.type === Blockly.Events.BLOCK_CHANGE && !event.isStart)
) {
setCurrency(this);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ Blockly.Blocks.multiplier_stop_loss = {
}
if (
(event.type === Blockly.Events.BLOCK_CREATE && event.ids.includes(this.id)) ||
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart)
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart) ||
(event.type === Blockly.Events.BLOCK_CHANGE && !event.isStart)
) {
setCurrency(this);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ Blockly.Blocks.multiplier_take_profit = {
}
if (
(event.type === Blockly.Events.BLOCK_CREATE && event.ids.includes(this.id)) ||
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart)
(event.type === Blockly.Events.BLOCK_DRAG && !event.isStart) ||
(event.type === Blockly.Events.BLOCK_CHANGE && !event.isStart)
) {
setCurrency(this);
}
Expand Down

0 comments on commit 2d3a483

Please sign in to comment.