Archived
fix response
This commit is contained in:
1 parent
11e7ff63f8
commit
5da902fb3b
1 file changed
+5
-1
+5
-1
@@ -43,6 +43,11 @@ export class HTTPServer {
|
||||
}
|
||||
|
||||
for await (const conn of this.server) {
|
||||
this.handleHttp(conn);
|
||||
}
|
||||
}
|
||||
|
||||
private async handleHttp(conn: Deno.Conn){
|
||||
const httpConn = Deno.serveHttp(conn);
|
||||
for await (const requestEvent of httpConn) {
|
||||
const url = new URL(requestEvent.request.url);
|
||||
@@ -112,7 +117,6 @@ export class HTTPServer {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
get(path: string, handler: RouteHandler) {
|
||||
this.add("GET", path, handler);
|
||||
|
||||
Reference in new issue
Block a user