(contents: any, childId: any)
| 27 | courseContent: any; |
| 28 | }) { |
| 29 | const findChildContent = (contents: any, childId: any) => { |
| 30 | for (const content of contents) { |
| 31 | if (content.id === childId) { |
| 32 | return content; |
| 33 | } else if (content.children && content.children.length > 0) { |
| 34 | const childContent: any = findChildContent(content.children, childId); |
| 35 | if (childContent) { |
| 36 | return childContent; |
| 37 | } |
| 38 | } |
| 39 | } |
| 40 | return undefined; |
| 41 | }; |
| 42 | |
| 43 | const generateBreadcrumbs = useMemo(() => { |
| 44 | const breadcrumbs = []; |
no outgoing calls
no test coverage detected