mirror of
https://github.com/Siccity/xNode.git
synced 2025-12-20 17:26:02 +08:00
A fix for an ArgumentException error. (#250)
This is the fix proposed by nostravaganza on discord. It works 100%. Could not reproduce the error again.
This commit is contained in:
parent
049a62465c
commit
e704b97c77
@ -74,8 +74,10 @@ namespace XNodeEditor {
|
|||||||
|
|
||||||
Attribute attr;
|
Attribute attr;
|
||||||
if (!typeTypes.TryGetValue(typeof(T), out attr)) {
|
if (!typeTypes.TryGetValue(typeof(T), out attr)) {
|
||||||
if (GetAttrib<T>(classType, fieldName, out attribOut)) typeTypes.Add(typeof(T), attribOut);
|
if (GetAttrib<T>(classType, fieldName, out attribOut)) {
|
||||||
else typeTypes.Add(typeof(T), null);
|
typeTypes.Add(typeof(T), attribOut);
|
||||||
|
return true;
|
||||||
|
} else typeTypes.Add(typeof(T), null);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (attr == null) {
|
if (attr == null) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user