Remove nullability from AdditionalData on ContentItemDisplay (#13380)

@Zeegaan We have a use case where we need to set a value in the AdditionalData dictionary in a NotificationHandler, but as it can be null, it requires reflection to make sure that is not the case. As such, it would be nice if the following change could be implemented to ensure it is never null.
This commit is contained in:
Nikolai Emil Damm
2022-11-10 14:13:10 +01:00
committed by Nikolaj
parent 13308c3610
commit c2047d1d6e

View File

@@ -201,7 +201,7 @@ public class ContentItemDisplay<TVariant> :
/// </summary>
[DataMember(Name = "metaData")]
[ReadOnly(true)]
public IDictionary<string, object>? AdditionalData { get; private set; }
public IDictionary<string, object> AdditionalData { get; private set; } = new Dictionary<string, object>();
/// <summary>
/// This is used for validation of a content item.