From 35eddf35c5651b883a65e955a750ddd2c05b47be Mon Sep 17 00:00:00 2001 From: Joseph Madamba Date: Mon, 22 Apr 2024 11:22:39 -0700 Subject: [PATCH] Return `Task.CompletedTask` instead of `null` --- osu.Game/Scoring/ScoreManager.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/osu.Game/Scoring/ScoreManager.cs b/osu.Game/Scoring/ScoreManager.cs index f37ee2b101..1ba5c7d4cf 100644 --- a/osu.Game/Scoring/ScoreManager.cs +++ b/osu.Game/Scoring/ScoreManager.cs @@ -201,16 +201,16 @@ namespace osu.Game.Scoring /// Export a replay from a given . /// /// The to export. - /// The . Null if the score cannot be found in the database. + /// The . Return if the score cannot be found in the database. /// /// The is re-retrieved from the database to ensure all the required data /// for exporting a replay are present (may have missing properties if it was retrieved from online data). /// - public Task? Export(ScoreInfo scoreInfo) + public Task Export(ScoreInfo scoreInfo) { ScoreInfo? databasedScoreInfo = getDatabasedScoreInfo(scoreInfo); - return databasedScoreInfo == null ? null : scoreExporter.ExportAsync(databasedScoreInfo.ToLive(Realm)); + return databasedScoreInfo == null ? Task.CompletedTask : scoreExporter.ExportAsync(databasedScoreInfo.ToLive(Realm)); } public Task?> ImportAsUpdate(ProgressNotification notification, ImportTask task, ScoreInfo original) => scoreImporter.ImportAsUpdate(notification, task, original);