Skip to content

Commit b7d42d7

Browse files
committed
fix: Implement backwards compatibility with old versions of nativescript-dev-webpack plugin
1 parent 6dacef8 commit b7d42d7

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

lib/common

lib/services/livesync/livesync-service.ts

+9-3
Original file line numberDiff line numberDiff line change
@@ -691,12 +691,18 @@ export class LiveSyncService extends EventEmitter implements IDebugLiveSyncServi
691691
},
692692
platforms
693693
},
694+
filesToSync,
694695
filesToSyncMap,
695696
filesToRemove,
696697
startSyncFilesTimeout: async (platform: string) => {
697-
filesToSync = filesToSyncMap[platform];
698-
await startSyncFilesTimeout(platform);
699-
filesToSyncMap[platform] = [];
698+
if (platform) {
699+
filesToSync = filesToSyncMap[platform];
700+
await startSyncFilesTimeout();
701+
filesToSyncMap[platform] = [];
702+
} else {
703+
// This code is added for backwards compatibility with old versions of nativescript-dev-webpack plugin.
704+
await startSyncFilesTimeout();
705+
}
700706
}
701707
}
702708
});

0 commit comments

Comments
 (0)