From 4177dc395bbb420ffca16f94a7313dc0c454393b Mon Sep 17 00:00:00 2001 From: eyhn Date: Fri, 20 Jun 2025 16:23:18 +0800 Subject: [PATCH 1/2] Fix beatmap set author information --- osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs b/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs index c6cf0f735f..d04c59c168 100644 --- a/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs +++ b/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs @@ -80,6 +80,11 @@ namespace osu.Game.Online.API.Requests.Responses [JsonProperty("artist_unicode")] public string ArtistUnicode { get; set; } = string.Empty; + /// + /// In the beatmap search API, this property is not provided. + /// In such cases, the following two properties will be used to provide the Author information. + /// + [JsonProperty(@"user")] public APIUser Author = new APIUser(); /// From b603a88043858f2fe1b627534ba309a8be7e4b95 Mon Sep 17 00:00:00 2001 From: Salman Alshamrani Date: Fri, 20 Jun 2025 20:21:44 +0300 Subject: [PATCH 2/2] Reword documentation --- .../API/Requests/Responses/APIBeatmapSet.cs | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs b/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs index d04c59c168..e8e08059b9 100644 --- a/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs +++ b/osu.Game/Online/API/Requests/Responses/APIBeatmapSet.cs @@ -81,15 +81,21 @@ namespace osu.Game.Online.API.Requests.Responses public string ArtistUnicode { get; set; } = string.Empty; /// - /// In the beatmap search API, this property is not provided. - /// In such cases, the following two properties will be used to provide the Author information. + /// The creator of this beatmap set. /// + /// + /// This is not included when the set is retrieved via , + /// but the creator's ID and username will be filled in this property from the and properties. + /// [JsonProperty(@"user")] public APIUser Author = new APIUser(); /// - /// Helper property to deserialize a username to . + /// The ID of the beatmap set's creator. /// + /// + /// Helper property to deserialize the ID to . + /// [JsonProperty(@"user_id")] public int AuthorID { @@ -98,8 +104,11 @@ namespace osu.Game.Online.API.Requests.Responses } /// - /// Helper property to deserialize a username to . + /// The username of the beatmap set's creator. /// + /// + /// Helper property to deserialize the username to . + /// [JsonProperty(@"creator")] public string AuthorString {