mirror of
https://github.com/Siccity/xNode.git
synced 2025-12-20 01:06:01 +08:00
use string substring instead of allocating a array with the two strings in it.
This commit is contained in:
parent
bdbb287f00
commit
f167313957
@ -97,7 +97,7 @@ namespace XNode {
|
|||||||
foreach (NodePort listPort in dynamicListPorts) {
|
foreach (NodePort listPort in dynamicListPorts) {
|
||||||
// At this point we know that ports here are dynamic list ports
|
// At this point we know that ports here are dynamic list ports
|
||||||
// which have passed name/"backing port" checks, ergo we can proceed more safely.
|
// which have passed name/"backing port" checks, ergo we can proceed more safely.
|
||||||
string backingPortName = listPort.fieldName.Split(' ')[0];
|
string backingPortName = listPort.fieldName.Substring(0, listPort.fieldName.IndexOf(' '));
|
||||||
NodePort backingPort = staticPorts[backingPortName];
|
NodePort backingPort = staticPorts[backingPortName];
|
||||||
|
|
||||||
// Update port constraints. Creating a new port instead will break the editor, mandating the need for setters.
|
// Update port constraints. Creating a new port instead will break the editor, mandating the need for setters.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user