8000 Fix trimming · dotnet/aspnetcore@3c4cc13 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3c4cc13

Browse files
committed
Fix trimming
1 parent 226b626 commit 3c4cc13

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/Components/Components/src/PersistentState/PersistentServicesRegistry.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ private static void PersistInstanceState(object instance, Type type, PersistentC
9292
}
9393

9494
[UnconditionalSuppressMessage("Trimming", "IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code", Justification = "<Pending>")]
95+
[DynamicDependency(LinkerFlags.JsonSerialized, typeof(PersistentComponentRegistration))]
9596
internal void Restore(PersistentComponentState state)
9697
{
9798
if (state.TryTakeFromJson<PersistentComponentRegistration[]>(_registryKey, out var registry) && registry != null)

0 commit comments

Comments
 (0)
0