Fixed build page when no project exists
[src/xds/xds-agent.git] / webapp / src / app / pages / build / settings / project-select-dropdown.component.ts
index a83ec0a..a99dc6b 100644 (file)
@@ -28,7 +28,9 @@ export class ProjectSelectDropdownComponent implements OnInit {
   }
 
   select() {
-    this.projectSvr.setCurrentById(this.curPrj.id);
+    if (this.curPrj) {
+      this.projectSvr.setCurrentById(this.curPrj.id);
+    }
   }
 }