Skip to content

Commit f843cb3

Browse files
committed
chore: remove unneeded code
1 parent 0899198 commit f843cb3

File tree

2 files changed

+7
-16
lines changed

2 files changed

+7
-16
lines changed

lib/services/livesync/playground/preview-app-livesync-service.ts

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -128,20 +128,10 @@ export class PreviewAppLiveSyncService implements IPreviewAppLiveSyncService {
128128
const platformData = this.$platformsData.getPlatformData(platform, projectData);
129129
const clonedFiles = _.cloneDeep(filesToSyncMap[platform]);
130130
const filesToSync = _.map(clonedFiles, fileToSync => {
131-
const result = path.join(platformData.appDestinationDirectoryPath, APP_FOLDER_NAME, path.relative(projectData.getAppDirectoryPath(), fileToSync));
132-
console.log(result);
133-
return result;
134-
});
135-
136-
// console.log("####### FILES TO SYNC!!!!!!! %%%%%%%% ", filesToSync, data.projectDir, platformData);
137-
// console.log("####### appDestinationDirectoryPath!!!! ", platformData.appDestinationDirectoryPath);
138-
// console.log("hjfjdjgdfjgjfgjgj !!!!! ", projectData.getAppDirectoryPath());
139-
140-
// filesToSync = filesToSync.map(fileToSync => {
141-
// console.log("appDestinationDirectoryPath !!!! ", platformData.appDestinationDirectoryPath);
142-
// console.log("relative path!!!!!", path.relative(projectData.getAppDirectoryPath(), fileToSync));
143-
// return result;
144-
// });
131+
const result = path.join(platformData.appDestinationDirectoryPath, APP_FOLDER_NAME, path.relative(projectData.getAppDirectoryPath(), fileToSync));
132+
return result;
133+
});
134+
145135
promise = this.syncFilesForPlatformSafe(data, { filesToSync }, platform);
146136
await promise;
147137

@@ -151,8 +141,10 @@ export class PreviewAppLiveSyncService implements IPreviewAppLiveSyncService {
151141
await Promise.all(_.map(devices, async (previewDevice: Device) => {
152142
const status = await this.$hmrStatusService.getHmrStatus(previewDevice.id, platformHmrData.hash);
153143
if (status === HmrConstants.HMR_ERROR_STATUS) {
154-
// TODO: SET useHotModuleReload: false,
144+
const originalUseHotModuleReload = data.useHotModuleReload;
145+
data.useHotModuleReload = false;
155146
await this.syncFilesForPlatformSafe(data, { filesToSync: platformHmrData.fallbackFiles }, platform, previewDevice.id );
147+
data.useHotModuleReload = originalUseHotModuleReload;
156148
}
157149
}));
158150
}

lib/services/livesync/playground/preview-sdk-service.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,6 @@ export class PreviewSdkService extends EventEmitter implements IPreviewSdkServic
7575
onDevicesPresence: (devices: Device[]) => this.$previewDevicesService.updateConnectedDevices(devices),
7676
onSendingChange: (sending: boolean) => ({ }),
7777
onBiggerFilesUpload: async (filesContent, callback) => {
78-
console.log("ON BIGGER FILES UPLOAD!!!!!!!!!!!!");
7978
const gzippedContent = Buffer.from(pako.gzip(filesContent));
8079
const byteLength = filesContent.length;
8180

0 commit comments

Comments
 (0)