Skip to content

Commit 255bd92

Browse files
author
Fatme
authored
Merge pull request #3618 from NativeScript/fatme/fix-doctor
Fix doctor
2 parents 460a359 + 0f6fcc3 commit 255bd92

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

lib/services/doctor-service.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,11 @@ class DoctorService implements IDoctorService {
3434
await this.$analyticsService.track("DoctorEnvironmentSetup", hasWarnings ? "incorrect" : "correct");
3535
}
3636

37-
this.printInfosCore(infos);
38-
3937
if (hasWarnings) {
4038
this.$logger.info("There seem to be issues with your configuration.");
4139
} else {
4240
this.$logger.out("No issues were detected.".bold);
41+
this.printInfosCore(infos);
4342
}
4443

4544
try {

lib/services/versions-service.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -100,14 +100,15 @@ class VersionsService implements IVersionsService {
100100
allComponents.push(nativescriptCliInformation);
101101
}
102102

103-
const nativescriptCoreModulesInformation: IVersionInformation = await this.getTnsCoreModulesVersion();
104-
if (nativescriptCoreModulesInformation) {
105-
allComponents.push(nativescriptCoreModulesInformation);
106-
}
107-
108-
const runtimesVersions: IVersionInformation[] = await this.getRuntimesVersions();
103+
if (this.projectData) {
104+
const nativescriptCoreModulesInformation: IVersionInformation = await this.getTnsCoreModulesVersion();
105+
if (nativescriptCoreModulesInformation) {
106+
allComponents.push(nativescriptCoreModulesInformation);
107+
}
109108

110-
allComponents = allComponents.concat(runtimesVersions);
109+
const runtimesVersions: IVersionInformation[] = await this.getRuntimesVersions();
110+
allComponents = allComponents.concat(runtimesVersions);
111+
}
111112

112113
return allComponents
113114
.map(componentInformation => {

0 commit comments

Comments
 (0)