Skip to content

Commit 4c5a728

Browse files
author
Andy Hanson
committed
Don't use ternary operator
1 parent 8a2d161 commit 4c5a728

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/server/scriptInfo.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,10 @@ namespace ts.server {
8484
}
8585

8686
getDefaultProject() {
87-
return this.containingProjects.length === 0 ? Errors.ThrowNoProject() : this.containingProjects[0];
87+
if (this.containingProjects.length === 0) {
88+
return Errors.ThrowNoProject();
89+
}
90+
return this.containingProjects[0];
8891
}
8992

9093
setFormatOptions(formatSettings: FormatCodeSettings): void {

0 commit comments

Comments
 (0)