mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-07-02 03:02:19 +08:00
fix(mbm): fix the error when deleting a collection contains m2m array fields (#5231)
This commit is contained in:
parent
60903d7c6d
commit
d0087f1998
@ -19,6 +19,9 @@ export function beforeDestroyForeignKey(db: Database) {
|
||||
|
||||
const fieldKeys = [];
|
||||
const collection = db.getCollection(collectionName);
|
||||
if (!collection) {
|
||||
return;
|
||||
}
|
||||
|
||||
for (const [, field] of collection.fields) {
|
||||
const fieldKey = field.options?.key;
|
||||
|
Loading…
x
Reference in New Issue
Block a user