Skip to content

Commit d471709

Browse files
committed
fix: import type
1 parent dcd60db commit d471709

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

packages/openapi-code-generator/src/typescript/server/typescript-nextjs/typescript-nextjs-router-builder.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,19 +32,18 @@ export class TypescriptNextjsRouterBuilder extends AbstractRouterBuilder {
3232
protected buildImports(): void {
3333
this.imports
3434
.from("@nahkies/typescript-nextjs-runtime/server")
35-
.add(
36-
"OpenAPIRuntimeResponse",
35+
.add("OpenAPIRuntimeResponse", "parseQueryParameters")
36+
.addType(
3737
"OpenAPIRuntimeResponder",
3838
"Params",
3939
"StatusCode2xx",
4040
"StatusCode3xx",
4141
"StatusCode4xx",
4242
"StatusCode5xx",
4343
"StatusCode",
44-
"parseQueryParameters",
4544
)
4645

47-
this.imports.from("next/server").add("NextRequest", "NextResponse")
46+
this.imports.from("next/server").addType("NextRequest", "NextResponse")
4847

4948
this.imports
5049
.from("@nahkies/typescript-nextjs-runtime/errors")

0 commit comments

Comments
 (0)