Skip to content

Commit

Permalink
Simplify frontend/src/components/InlineMenu/Menu.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
dtrucs committed Apr 4, 2024
1 parent 0df4b3c commit 96e5cf3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions frontend/src/components/InlineMenu/Menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ export const Menu: React.FC<MenuProps> = ({
const { contentClassName, itemClassName, expandedClassName, groupClassName } = useMemo(() => {
if (
menuItems.some(
({ children }) =>
children && (children.length > 5 || children.some(({ thumbnail }) => thumbnail !== null)),
({ children = [] }) =>
children.length > 5 || children.some(({ thumbnail }) => thumbnail !== null),
)
) {
return {
Expand Down

0 comments on commit 96e5cf3

Please sign in to comment.