Closed b-ma closed 1 year ago
Problem is observe
return unobserve
, maybe we could rather return an Observer { promise, unobserve }
done in v4
unobserve
in the value of the resolved Promise:
const unobserve = await server.stateManager.observe([schemaName, ] callback);
make
stateManager.observe(func)
asynchronous, resolving when the callback has been fully executed the first time.