Commit d6bc9ec6 authored by Igor Stuev's avatar Igor Stuev Committed by GitHub

Update lib/hooks/useNavItems.tsx

Co-authored-by: default avatartom goriunov <tom@ohhhh.me>
parent fbb96d9c
......@@ -43,10 +43,7 @@ interface ReturnType {
}
export function isGroupItem(item: NavItem | NavGroupItem): item is NavGroupItem {
if ((item as NavGroupItem).subItems) {
return true;
}
return false;
return 'subItems' in item;
}
export default function useNavItems(): ReturnType {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment