Skip to content

Commit af44738

Browse files
committed
Fix lint
1 parent fda4c7c commit af44738

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

packages/docs/loaders/stars.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
const GITHUB_TOKEN = process.env.GITHUB_TOKEN!;
22
const API_URL = "https://api.github.com/graphql";
33

4-
export async function fetchStars(
5-
resources: { slug: string; stars?: number }[],
6-
) {
4+
export async function fetchStars(resources: { slug: string; stars?: number }[]) {
75
try {
86
if (resources.length === 0) return;
97
const uniqueSlugs = Array.from(
@@ -13,8 +11,8 @@ export async function fetchStars(
1311
.map((r, id) => ({
1412
id,
1513
slug: r.slug,
16-
})),
17-
),
14+
}))
15+
)
1816
);
1917

2018
if (uniqueSlugs.length === 0) return;
@@ -40,7 +38,7 @@ export async function fetchStars(
4038

4139
if (res.status > 400) {
4240
console.error(
43-
"Failed to fetch GitHub stars. Make sure you are providing a valid GITHUB_TOKEN in packages/docs/.env",
41+
"Failed to fetch GitHub stars. Make sure you are providing a valid GITHUB_TOKEN in packages/docs/.env"
4442
);
4543
if (process.env.NODE_ENV === "production") {
4644
throw new Error("Failed to fetch GitHub stars.");

0 commit comments

Comments
 (0)