Skip to content

Commit cb56f67

Browse files
authored
Update scope.jl
1 parent c259287 commit cb56f67

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/scope.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ function JSON.lower(scope::Scope)
242242
if sync === nothing
243243
# by default, we sync if there are any listeners
244244
# other than the JS back edge
245-
sync = any(f-> !isa(f, SyncCallback), listeners(ob))
245+
sync = any(((_, f),) -> !isa(f, SyncCallback), listeners(ob))
246246
end
247247
obs_dict[k] = Dict(
248248
"sync" => sync,
@@ -374,11 +374,11 @@ function offjs(ctx, key, f)
374374
end
375375
nothing
376376
end
377-
377+
378378
function ensure_sync(ctx, key)
379379
ob = ctx.observs[key][1]
380380
# have at most one synchronizing handler per observable
381-
if !any(x->isa(x, SyncCallback) && x.ctx==ctx, listeners(ob))
381+
if !any(((_, x),) ->isa(x, SyncCallback) && x.ctx==ctx, listeners(ob))
382382
f = SyncCallback(ctx, (msg) -> send_update_observable(ctx, key, msg))
383383
on(SyncCallback(ctx, f), ob)
384384
end

0 commit comments

Comments
 (0)