aboutsummaryrefslogtreecommitdiffstats
path: root/src/io
diff options
context:
space:
mode:
Diffstat (limited to 'src/io')
-rw-r--r--src/io/lineedit.nim2
-rw-r--r--src/io/request.nim3
-rw-r--r--src/io/response.nim2
3 files changed, 7 insertions, 0 deletions
diff --git a/src/io/lineedit.nim b/src/io/lineedit.nim
index 51bf7cd9..66a4eede 100644
--- a/src/io/lineedit.nim
+++ b/src/io/lineedit.nim
@@ -37,6 +37,8 @@ type
histindex: int
histtmp: string
+jsDestructor(LineEdit)
+
func newLineHistory*(): LineHistory =
return LineHistory()
diff --git a/src/io/request.nim b/src/io/request.nim
index 86c8a38d..93ec9b7d 100644
--- a/src/io/request.nim
+++ b/src/io/request.nim
@@ -83,6 +83,9 @@ type
Headers* = ref object
table* {.jsget.}: Table[string, seq[string]]
+jsDestructor(Request)
+jsDestructor(Headers)
+
proc js_url(this: Request): string {.jsfget: "url".} =
return $this.url
diff --git a/src/io/response.nim b/src/io/response.nim
index fbe5339e..5c0253e9 100644
--- a/src/io/response.nim
+++ b/src/io/response.nim
@@ -21,6 +21,8 @@ type
unregisterFun*: proc()
bodyRead*: Promise[string]
+jsDestructor(Response)
+
proc newResponse*(res: int, request: Request, fd = -1, stream: Stream = nil):
Response =
return Response(