]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/dashboard: fix Cannot read properties of undefined (reading 'filter') 47959/head
authorNizamudeen A <nia@redhat.com>
Sun, 4 Sep 2022 05:52:45 +0000 (11:22 +0530)
committerNizamudeen A <nia@redhat.com>
Sun, 4 Sep 2022 05:52:45 +0000 (11:22 +0530)
Fixes: https://tracker.ceph.com/issues/57434
Signed-off-by: Nizamudeen A <nia@redhat.com>
src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/services/service-form/service-form.component.ts

index 83bb099fb4151ff7fe1e8e9de2112be67b9e8c4e..bd007eba5194073b76e318bc416d534e0ba77698 100644 (file)
@@ -485,7 +485,7 @@ export class ServiceFormComponent extends CdForm implements OnInit {
 
   getServiceIds(selectedServiceType: string) {
     this.serviceIds = this.serviceList
-      .filter((service) => service['service_type'] === selectedServiceType)
+      ?.filter((service) => service['service_type'] === selectedServiceType)
       .map((service) => service['service_id']);
   }