fix(db-mongodb): strip deleted from the config blocks from the result (#12869)

If you (using the MongoDB adapter) delete a block from the payload
config, but still have some data with that block in the DB, you'd
receive in the admin panel an error like:
```
Block with type "cta" was found in block data, but no block with that type is defined in the config for field with schema path pages.blocks
```

Now, we remove those "unknown" blocks at the DB adapter level.

Co-authored-by: Dan Ribbens <dan.ribbens@gmail.com>
This commit is contained in:
Sasha
2025-06-27 12:30:48 +03:00
committed by GitHub
parent 3830d710a4
commit 54afaf9529
7 changed files with 96 additions and 19 deletions

View File

@@ -1,5 +1,5 @@
import { CustomView as CustomView_c4f0e2747eca2be436a06a63cea31567 } from '../../CustomView/index.js'
export const importMap = {
"/CustomView/index.js#CustomView": CustomView_c4f0e2747eca2be436a06a63cea31567
'/CustomView/index.js#CustomView': CustomView_c4f0e2747eca2be436a06a63cea31567,
}