mirror of
https://github.com/ComradCollective/Comrad
synced 2024-11-17 21:25:37 +00:00
wait maybe it is
This commit is contained in:
parent
de6739d9b9
commit
ceae6a4dca
@ -48,7 +48,7 @@ class Api(object):
|
|||||||
# self.node = self.connect()
|
# self.node = self.connect()
|
||||||
log('starting selfless daemon...')
|
log('starting selfless daemon...')
|
||||||
self.selfless = Thread(target=start_selfless_thread)
|
self.selfless = Thread(target=start_selfless_thread)
|
||||||
# self.selfless.daemon = True
|
self.selfless.daemon = True
|
||||||
self.selfless.start()
|
self.selfless.start()
|
||||||
pass
|
pass
|
||||||
|
|
||||||
@ -70,13 +70,10 @@ class Api(object):
|
|||||||
from .kad import KadServer
|
from .kad import KadServer
|
||||||
|
|
||||||
async def _get():
|
async def _get():
|
||||||
if not hasattr(self,'node'):
|
node = KadServer() #storage=HalfForgetfulStorage())
|
||||||
self.node = node = KadServer() #storage=HalfForgetfulStorage())
|
|
||||||
await node.listen(PORT_LISTEN)
|
await node.listen(PORT_LISTEN)
|
||||||
await node.bootstrap(NODES_PRIME)
|
await node.bootstrap(NODES_PRIME)
|
||||||
# node=self.node
|
# node=self.node
|
||||||
else:
|
|
||||||
node = self.node
|
|
||||||
|
|
||||||
if type(key_or_keys) in {list,tuple,dict}:
|
if type(key_or_keys) in {list,tuple,dict}:
|
||||||
keys = key_or_keys
|
keys = key_or_keys
|
||||||
|
Loading…
Reference in New Issue
Block a user