Fix #127213: crash on undo after unlinking an object in the outliner
This commit is contained in:
@@ -460,6 +460,7 @@ static void unlink_object_fn(bContext *C,
|
||||
case ID_GR: {
|
||||
Collection *parent = (Collection *)tsep->id;
|
||||
BKE_collection_object_remove(bmain, parent, ob, true);
|
||||
DEG_id_tag_update(&parent->id, ID_RECALC_SYNC_TO_EVAL);
|
||||
break;
|
||||
}
|
||||
case ID_SCE: {
|
||||
@@ -478,6 +479,7 @@ static void unlink_object_fn(bContext *C,
|
||||
else {
|
||||
Collection *parent = scene->master_collection;
|
||||
BKE_collection_object_remove(bmain, parent, ob, true);
|
||||
DEG_id_tag_update(&parent->id, ID_RECALC_SYNC_TO_EVAL);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user