Skip to content

Commit

Permalink
Marked deprecated ReadOnlyTopicCollection<T>.FromList() as obsolete
Browse files Browse the repository at this point in the history
This functionality is effectively satisfied by the related overload, which accepts an `IList<T>` to prepopulate the collection.

This simply moves the method from deprecated to obsolete so that it now throws an exception if used. In a future version, we will remove this entirely.
  • Loading branch information
JeremyCaney committed Dec 17, 2020
1 parent 6d1240f commit b013e38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion OnTopic/Collections/ReadOnlyTopicCollection{T}.cs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public class ReadOnlyTopicCollection<T> : ReadOnlyCollection<T> where T : Topic
/// The <paramref name="innerCollection"/> will be converted to a <see cref="TopicCollection{T}"/>.
/// </remarks>
/// <param name="innerCollection">The underlying <see cref="TopicCollection{T}"/>.</param>
[Obsolete("This is effectively satisfied by the related overload, and will be removed in OnTopic 5.0.0.", false)]
[Obsolete("This is effectively satisfied by the related overload, and will be removed in OnTopic 5.0.0.", true)]
public ReadOnlyTopicCollection<T> FromList(IList<T> innerCollection) {
Contract.Requires(innerCollection, "innerCollection should not be null");
return new(innerCollection);
Expand Down

0 comments on commit b013e38

Please sign in to comment.