Skip to content

Commit 5af8414

Browse files
authoredOct 2, 2024··
Change condition to check if it is array
1 parent aefa2a2 commit 5af8414

File tree

1 file changed

+1
-1
lines changed
  • src/app/(public)/repos/[language]

1 file changed

+1
-1
lines changed
 

‎src/app/(public)/repos/[language]/page.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ async function getRepos(
133133
return !repo.archived && !reports.find(report => report.repoId === repo.id);
134134
});
135135

136-
if (!repos.items || repos.items.length < 1) notFound();
136+
if (!Array.isArray(repos.items) || repos.items.length < 1) notFound();
137137

138138
return {
139139
page: +page.toString(),

0 commit comments

Comments
 (0)
Please sign in to comment.