mirror of
https://github.com/littensy/charm.git
synced 2026-10-23 05:46:27 +00:00
fix: avoid reconnecting to dependencies after cleanup (#14)
* fix: cancel reconnection when unsubscribing * test: remove print * feat: allow factory to return nil * perf: use `next` iteration
This commit is contained in:
parent
62be3e496d
commit
c6762a6525
14 changed files with 87 additions and 63 deletions
|
|
@ -36,7 +36,7 @@ local function client(options: ClientOptions): ClientSyncer
|
|||
for index = 1, select("#", ...) do
|
||||
local payload = select(index, ...)
|
||||
|
||||
for key, state in payload.data do
|
||||
for key, state in next, payload.data do
|
||||
if payload.type == "patch" then
|
||||
atoms[key](patch.apply(atoms[key](), state))
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue