]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/shared/shared-main/misc/top-menu-dropdown.component.ts
Fix avatar default size
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-main / misc / top-menu-dropdown.component.ts
index 2cafb6c55c6d68f50d17106b7e675afdeb7650b8..a8cc9b593fa9d263536eb7f0bac5afba676622a6 100644 (file)
@@ -66,7 +66,7 @@ export class TopMenuDropdownComponent implements OnInit, OnDestroy {
       .subscribe(() => this.updateChildLabels(window.location.pathname))
 
     this.hasIcons = this.menuEntries.some(
-      e => e.children && e.children.some(c => !!c.iconName)
+      e => e.children?.some(c => !!c.iconName)
     )
   }
 
@@ -84,8 +84,9 @@ export class TopMenuDropdownComponent implements OnInit, OnDestroy {
 
     this.modalService.open(this.modal, {
       centered: true,
-      beforeDismiss: async () => {
+      beforeDismiss: () => {
         this.onModalDismiss()
+
         return true
       }
     })