feat(core): new worker workspace engine (#9257)

This commit is contained in:
EYHN
2025-01-17 00:22:18 +08:00
committed by GitHub
parent 7dc470e7ea
commit a2ffdb4047
219 changed files with 4267 additions and 7194 deletions
@@ -18,8 +18,11 @@ export class AwarenessSyncImpl implements AwarenessSync {
async update(record: AwarenessRecord, origin?: string) {
await Promise.all(
[this.storages.local, ...Object.values(this.storages.remotes)].map(peer =>
peer.update(record, origin)
[this.storages.local, ...Object.values(this.storages.remotes)].map(
peer =>
peer.connection.status === 'connected'
? peer.update(record, origin)
: Promise.resolve()
)
);
}