Skip to content

Commit 0939af1

Browse files
committed
Update Service.cpp
1 parent 4eee4d5 commit 0939af1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Foundation/Public/Aurora.Scene/Service.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ namespace Scene
246246
Second = Component;
247247
}
248248

249-
ConstPtr<Factory> Serializer = Second.Find<const Factory>();
249+
ConstPtr<Factory> Serializer = Second.IsValid() ? Second.Find<const Factory>() : nullptr;
250250

251251
if (Serializer && (First.IsNull() || First.Contains<Factory>()))
252252
{

0 commit comments

Comments
 (0)