Browse Source

Fix the load of initial blocks. Fixes #6518 (#6538)

Fix load of initial blocks
fix-broken-styles-import
Artur Arseniev 8 months ago
committed by GitHub
parent
commit
0ac498c467
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 2
      packages/core/src/block_manager/index.ts

2
packages/core/src/block_manager/index.ts

@ -72,11 +72,11 @@ export default class BlockManager extends ItemManagerModule<BlockManagerConfig,
onInit() {
const { config, blocks, blocksVisible } = this;
blocks.add(config.blocks || []);
// Setup the sync between the global and public collections
blocks.on('add', (model) => blocksVisible.add(model));
blocks.on('remove', (model) => blocksVisible.remove(model));
blocks.on('reset', (coll) => blocksVisible.reset(coll.models));
blocks.add(config.blocks || []);
}
/**

Loading…
Cancel
Save