Skip to content

Commit

Permalink
en #9: fixed exception when deleting sprite
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidLeoni committed Oct 22, 2020
1 parent 10fd4ce commit eeb7313
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/extensions/botch/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,15 +189,16 @@ class Scratch3Botch {

this.runtime.on(Runtime.SCRIPT_GLOW_OFF, (params => {
log.log('script glowing off:', params);
this.resetStoragePendingRequests(params.id);

this.resetStoragePendingRequests(params.id); // blockId
}));
this.runtime.on(Runtime.BLOCK_GLOW_OFF, params => {
log.log('block glowing off:', params);
this.resetStoragePendingRequests(params.id);
this.resetStoragePendingRequests(params.id); // blockId
});
this.runtime.on(Runtime.STOP_FOR_TARGET, params => {
log.log('STOP_FOR_TARGET:', params);
for (const blockId in params.target.blocks._blocks){
this.runtime.on(Runtime.STOP_FOR_TARGET, target => {
log.log('STOP_FOR_TARGET:', target);
for (const blockId in target.blocks._blocks){
this.resetStoragePendingRequests(blockId);
}
});
Expand Down

0 comments on commit eeb7313

Please sign in to comment.