mirror of
https://github.com/denoland/deno.git
synced 2025-01-08 15:19:40 -05:00
fix(std/http): update listenAndServe argument type (#3775)
allow same argument type for `listenAndServe` as `serve`. fixes: #3774
This commit is contained in:
parent
bc89f04cbf
commit
11a29fdb44
1 changed files with 1 additions and 1 deletions
|
@ -494,7 +494,7 @@ export function serve(addr: string | ServerConfig): Server {
|
|||
}
|
||||
|
||||
export async function listenAndServe(
|
||||
addr: string,
|
||||
addr: string | ServerConfig,
|
||||
handler: (req: ServerRequest) => void
|
||||
): Promise<void> {
|
||||
const server = serve(addr);
|
||||
|
|
Loading…
Reference in a new issue