diff --git a/src/GameCult.Caching/CultInspectorModel.cs b/src/GameCult.Caching/CultInspectorModel.cs index 7c3cb45e..efb602d3 100644 --- a/src/GameCult.Caching/CultInspectorModel.cs +++ b/src/GameCult.Caching/CultInspectorModel.cs @@ -561,7 +561,7 @@ namespace GameCult.Caching CultInspectorGrouping Refused(string reason) => new CultInspectorGrouping(listed, Array.Empty(), $"[CultInspectorGroupBy] on {listed.Name}: {reason} The list is not grouped."); - if (listed.GetCustomAttribute(true) != null) + if (listed.GetCustomAttribute() != null) return Refused("a global document is never grouped."); var members = new List(); foreach (var name in declared.Members) diff --git a/tests/GameCult.Caching.Tests/CultInspectorModelTests.cs b/tests/GameCult.Caching.Tests/CultInspectorModelTests.cs index 3432c858..bf0c815a 100644 --- a/tests/GameCult.Caching.Tests/CultInspectorModelTests.cs +++ b/tests/GameCult.Caching.Tests/CultInspectorModelTests.cs @@ -630,7 +630,6 @@ namespace GameCult.Caching.Tests [TestCase(typeof(GroupDuplicate), "Kind")] [TestCase(typeof(GroupValidThenInvalid), "Mass")] [TestCase(typeof(GroupGlobal), "global")] - [TestCase(typeof(GroupGlobalChild), "global")] public void GroupInvalidDeclarationsGiveANoticeAndAFlatList(Type listed, string mentions) { var model = GroupModel(); @@ -888,17 +887,12 @@ namespace GameCult.Caching.Tests [CultGlobal] [CultDocument("tests.group_global", "tests.group_global.v1")] [MessagePackObject] - public class GroupGlobal + public sealed class GroupGlobal { [Key(0)] public string Kind = string.Empty; } - [CultInspectorGroupBy("Kind")] - public sealed class GroupGlobalChild : GroupGlobal - { - } - [CultInspectorGroupBy("Kind")] [CultDocument("tests.group_no_ctor", "tests.group_no_ctor.v1")] [MessagePackObject]