diff --git a/workers/unity/Packages/io.improbable.gdk.core/Subscriptions/RequiredSubscriptionsInjector.cs b/workers/unity/Packages/io.improbable.gdk.core/Subscriptions/RequiredSubscriptionsInjector.cs index 73e7d88814..9a782375c4 100644 --- a/workers/unity/Packages/io.improbable.gdk.core/Subscriptions/RequiredSubscriptionsInjector.cs +++ b/workers/unity/Packages/io.improbable.gdk.core/Subscriptions/RequiredSubscriptionsInjector.cs @@ -77,6 +77,14 @@ private void HandleSubscriptionsSatisfied() private void HandleSubscriptionsNoLongerSatisfied() { onDisable?.Invoke(); + + foreach (var field in info.RequiredFields) + { + if (!field.FieldType.IsValueType) + { + field.SetValue(target, value: null); + } + } } private class Handler : ISubscriptionAvailabilityHandler