mirror of
https://github.com/logos-storage/nim-datastore.git
synced 2026-02-20 13:43:13 +00:00
more docs
This commit is contained in:
parent
59de213ac8
commit
35d8f76649
@ -78,6 +78,10 @@ proc init*(
|
||||
|
||||
type
|
||||
|
||||
## These type are equivalent thread-safe types
|
||||
## for copying / sharing query data between threads.
|
||||
##
|
||||
|
||||
QueryBuffer* = object
|
||||
key*: KeyBuffer # Key to be queried
|
||||
value*: bool # Flag to indicate if data should be returned
|
||||
@ -143,5 +147,6 @@ proc convert*(
|
||||
if ret[].results.isOk():
|
||||
result.ok(ret[].results.get().toQueryResponse())
|
||||
else:
|
||||
let exc: ref CatchableError = ret[].results.error().toCatchable()
|
||||
let exc: ref CatchableError =
|
||||
ret[].results.error().toCatchable()
|
||||
result.err(exc)
|
||||
|
||||
@ -88,8 +88,6 @@ proc convert*[T, S](ret: TResult[T],
|
||||
result.ok(ret[].results.get().toString())
|
||||
elif S is void:
|
||||
result.ok()
|
||||
# elif S is QueryResponse:
|
||||
# result.ok(ret[].results.get().toQueryResponse())
|
||||
else:
|
||||
result.ok(ret[].results.get())
|
||||
else:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user