File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -674,8 +674,6 @@ class Blocks {
674
674
}
675
675
}
676
676
677
- // TODO maybe track actual changes,
678
- // but for now, emit a project change always
679
677
this . emitProjectChanged ( ) ;
680
678
681
679
this . resetCache ( ) ;
Original file line number Diff line number Diff line change @@ -562,15 +562,14 @@ class VirtualMachine extends EventEmitter {
562
562
. then ( validatedInput => {
563
563
const projectVersion = validatedInput [ 0 ] . projectVersion ;
564
564
if ( projectVersion === 2 ) {
565
- return this . _addSprite2 ( validatedInput [ 0 ] , validatedInput [ 1 ] )
566
- . then ( ( ) => this . runtime . emitProjectChanged ( ) ) ;
565
+ return this . _addSprite2 ( validatedInput [ 0 ] , validatedInput [ 1 ] ) ;
567
566
}
568
567
if ( projectVersion === 3 ) {
569
- return this . _addSprite3 ( validatedInput [ 0 ] , validatedInput [ 1 ] )
570
- . then ( ( ) => this . runtime . emitProjectChanged ( ) ) ;
568
+ return this . _addSprite3 ( validatedInput [ 0 ] , validatedInput [ 1 ] ) ;
571
569
}
572
570
return Promise . reject ( `${ errorPrefix } Unable to verify sprite version.` ) ;
573
571
} )
572
+ . then ( ( ) => this . runtime . emitProjectChanged ( ) )
574
573
. catch ( error => {
575
574
// Intentionally rejecting here (want errors to be handled by caller)
576
575
if ( error . hasOwnProperty ( 'validationError' ) ) {
You can’t perform that action at this time.
0 commit comments