Skip to content

Commit d94a5ec

Browse files
authored
Remove App_Resources, when the changes are in the other files. (#2701)
1 parent 1b19adf commit d94a5ec

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lib/services/platform-service.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,12 +283,21 @@ export class PlatformService extends EventEmitter implements IPlatformService {
283283

284284
if (!changesInfo || changesInfo.appFilesChanged) {
285285
await this.copyAppFiles(platform, appFilesUpdaterOptions, projectData);
286+
287+
// remove the App_Resources folder from the app/assets as here we're applying other files changes.
288+
const appDestinationDirectoryPath = path.join(platformData.appDestinationDirectoryPath, constants.APP_FOLDER_NAME);
289+
const appResourcesDirectoryPath = path.join(appDestinationDirectoryPath, constants.APP_RESOURCES_FOLDER_NAME);
290+
if (this.$fs.exists(appResourcesDirectoryPath)) {
291+
this.$fs.deleteDirectory(appResourcesDirectoryPath);
292+
}
286293
}
294+
287295
if (!changesInfo || changesInfo.appResourcesChanged) {
288296
await this.copyAppFiles(platform, appFilesUpdaterOptions, projectData);
289297
this.copyAppResources(platform, projectData);
290298
await platformData.platformProjectService.prepareProject(projectData, platformSpecificData);
291299
}
300+
292301
if (!changesInfo || changesInfo.modulesChanged) {
293302
await this.copyTnsModules(platform, projectData);
294303
}

0 commit comments

Comments
 (0)