mirror of
https://github.com/Siccity/xNode.git
synced 2026-03-26 22:49:02 +08:00
switched order of remove function and destroy function.
target.RemoveNode was always getting a null value
This commit is contained in:
parent
7ca9100a69
commit
6c76f9a2c2
@ -94,8 +94,8 @@ namespace XNodeEditor {
|
|||||||
|
|
||||||
/// <summary> Safely remove a node and all its connections. </summary>
|
/// <summary> Safely remove a node and all its connections. </summary>
|
||||||
public virtual void RemoveNode(XNode.Node node) {
|
public virtual void RemoveNode(XNode.Node node) {
|
||||||
UnityEngine.Object.DestroyImmediate(node, true);
|
|
||||||
target.RemoveNode(node);
|
target.RemoveNode(node);
|
||||||
|
UnityEngine.Object.DestroyImmediate(node, true);
|
||||||
if (NodeEditorPreferences.GetSettings().autoSave) AssetDatabase.SaveAssets();
|
if (NodeEditorPreferences.GetSettings().autoSave) AssetDatabase.SaveAssets();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user