From ba345e559131e2c7c9dadc1237346c45883119e8 Mon Sep 17 00:00:00 2001 From: cdwcgt Date: Thu, 23 Feb 2023 20:10:50 +0900 Subject: [PATCH] delete notify post when duplicate export --- osu.Game/Database/LegacyModelExporter.cs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/osu.Game/Database/LegacyModelExporter.cs b/osu.Game/Database/LegacyModelExporter.cs index 96104a68a0..c826b37689 100644 --- a/osu.Game/Database/LegacyModelExporter.cs +++ b/osu.Game/Database/LegacyModelExporter.cs @@ -60,7 +60,7 @@ namespace osu.Game.Database /// If specified CancellationToken, then use it. Otherwise use PostNotification's CancellationToken. /// /// - public async Task ExportAsync(TModel model, CancellationToken? cancellationToken = null) + public async Task ExportAsync(TModel model, CancellationToken? cancellationToken = null) { // check if the model is being exporting already if (!exportingModels.Contains(model)) @@ -69,10 +69,7 @@ namespace osu.Game.Database } else { - PostNotification?.Invoke(new SimpleErrorNotification - { - Text = "File is being exported" - }); + // model is being exported return; } @@ -114,6 +111,8 @@ namespace osu.Game.Database exportingModels.Remove(model); } + + return success; } ///