From c4a7fe923cc0ad8d6bbc26913866669e4d5790bc Mon Sep 17 00:00:00 2001 From: bung87 Date: Sat, 13 Apr 2024 02:11:16 +0800 Subject: [PATCH] v1.2.2 --- scorper.nimble | 2 +- src/scorper/http/streamserver.nim | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scorper.nimble b/scorper.nimble index 15019c2..69ad703 100644 --- a/scorper.nimble +++ b/scorper.nimble @@ -1,6 +1,6 @@ # Package -version = "1.2.1" +version = "1.2.2" author = "bung87" description = "micro and elegant web framework" license = "Apache License 2.0" diff --git a/src/scorper/http/streamserver.nim b/src/scorper/http/streamserver.nim index f9332e0..b28380c 100644 --- a/src/scorper/http/streamserver.nim +++ b/src/scorper/http/streamserver.nim @@ -192,7 +192,7 @@ proc resp*(req: ImpRequest, content: sink string, await resp(req, content, headers.newHttpHeaders()) proc respError*(req: ImpRequest, code: HttpCode, content: sink string, headers = newHttpHeaders()): Future[ - void] {.async:(raises:[]).} = + void] {.async.} = ## Responds to the req with the specified ``HttpCode``. if req.responded == true: return @@ -212,10 +212,10 @@ proc respError*(req: ImpRequest, code: HttpCode, content: sink string, headers = req.responded = true proc respError*(req: ImpRequest, code: HttpCode, content: sink string, - headers: seq[(string, string)]): Future[void] {.inline, async: (raises:[]).} = + headers: seq[(string, string)]): Future[void] {.inline, async.} = await respError(req, code, content, headers.newHttpHeaders()) -proc respError*(req: ImpRequest, code: HttpCode, headers = newHttpHeaders()): Future[void] {.async:(raises: []).} = +proc respError*(req: ImpRequest, code: HttpCode, headers = newHttpHeaders()): Future[void] {.async.} = ## Responds to the req with the specified ``HttpCode``. if req.responded == true: return