Skip to content

Commit

Permalink
feat: allow synchronous route implementations
Browse files Browse the repository at this point in the history
  • Loading branch information
swain committed May 31, 2022
1 parent 8da04f2 commit 61eb6b8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/koa.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ export type ImplementationOf<Schema extends OneSchema<any>, State, Context> = {
: { body: EndpointsOf<Schema>[Name]['Request'] };
}
>,
) => Promise<EndpointsOf<Schema>[Name]['Response']>;
) =>
| EndpointsOf<Schema>[Name]['Response']
| Promise<EndpointsOf<Schema>[Name]['Response']>;
};

/**
Expand Down

0 comments on commit 61eb6b8

Please sign in to comment.