Skip to content

Commit

Permalink
Merge pull request #46 from techno-dwarf-works/feature/refactoring
Browse files Browse the repository at this point in the history
Version 0.0.43
  • Loading branch information
uurha authored Aug 18, 2024
2 parents 29d965a + fd29d70 commit a8f162c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,14 @@ public static CachedFieldInfo GetFieldInfoAndStaticTypeFromProperty(this Seriali
var fieldPath = self.propertyPath;
if (self.propertyType == SerializedPropertyType.ManagedReference)
{
var objectTypename = self.managedReferenceFullTypename;
if (!SerializedPropertyUtility.GetTypeFromManagedReferenceFullTypeName(objectTypename, out classType))
if (!self.managedReferenceFullTypename.IsNullOrEmpty())
{
return null;
var objectTypename = self.managedReferenceFullTypename;

if (!SerializedPropertyUtility.GetTypeFromManagedReferenceFullTypeName(objectTypename, out classType))
{
return null;
}
}

fieldPath = self.propertyPath;
Expand Down Expand Up @@ -231,7 +235,7 @@ public static bool IsDisposed(this SerializedProperty self)
{
return false;
}

try
{
if (PropertyPrtInfo != null && ObjectPrtInfo != null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,11 @@ public static bool GetTypeFromManagedReferenceFullTypeName(string managedReferen
var classNamePart = parts[1];
managedReferenceInstanceType = Type.GetType($"{classNamePart}, {assemblyPart}");
}
else
{
managedReferenceInstanceType = null;
}

managedReferenceInstanceType = null;
return managedReferenceInstanceType != null;
}

Expand Down
2 changes: 1 addition & 1 deletion Assets/BetterCommons/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "com.tdw.better.commons",
"displayName": "Better Commons",
"version": "0.0.42",
"version": "0.0.43",
"unity": "2021.3",
"description": " ",
"dependencies": {
Expand Down

0 comments on commit a8f162c

Please sign in to comment.