1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-14 19:22:56 +08:00

Fix crash when clicking on ShowMore button

This commit is contained in:
Andrei Zavatski 2020-02-24 05:53:33 +03:00
parent 66317f9fcd
commit b0b52146ea

View File

@ -96,12 +96,17 @@ namespace osu.Game.Overlays.Comments
{
var orphaned = new List<Comment>();
// Exclude possible duplicated comments.
foreach (var topLevel in bundle.Comments)
{
if (commentDictionary.ContainsKey(topLevel.Id))
continue;
addNewComment(topLevel);
}
foreach (var child in bundle.IncludedComments)
{
// Included comments can contain the parent comment, which already exists in the hierarchy.
if (commentDictionary.ContainsKey(child.Id))
continue;