Skip to content

Commit 12c821c

Browse files
committed
Fixes incorrect types
1 parent 9805658 commit 12c821c

File tree

1 file changed

+2
-8
lines changed
  • src/app/api/blob/[owner]/[repository]/[...path]

1 file changed

+2
-8
lines changed

src/app/api/blob/[owner]/[repository]/[...path]/route.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,7 @@ import { NextRequest, NextResponse } from "next/server"
22
import { session, userGitHubClient } from "@/composition"
33
import { makeUnauthenticatedAPIErrorResponse } from "@/common"
44

5-
interface GetBlobParams {
6-
owner: string
7-
repository: string
8-
path: [string]
9-
}
10-
11-
export async function GET(req: NextRequest, { params }: { params: Promise<GetBlobParams> }) {
5+
export async function GET(req: NextRequest, { params }: { params: Promise<{ owner: string; repository: string; path: string[] }> }) {
126
const isAuthenticated = await session.getIsAuthenticated()
137
if (!isAuthenticated) {
148
return makeUnauthenticatedAPIErrorResponse()
@@ -33,4 +27,4 @@ export async function GET(req: NextRequest, { params }: { params: Promise<GetBlo
3327
headers.set("Content-Type", "text/plain");
3428
}
3529
return new NextResponse(file, { status: 200, headers })
36-
}
30+
}

0 commit comments

Comments
 (0)