mirror of
https://github.com/ppy/osu.git
synced 2025-02-16 01:03:21 +08:00
Fix one more instance of improperly handled cancellation
This commit is contained in:
parent
e12b03e275
commit
b79fdfc12f
@ -436,8 +436,7 @@ namespace osu.Game.Beatmaps
|
|||||||
|
|
||||||
private void perform(BeatmapInfo beatmap, CancellationToken cancellation)
|
private void perform(BeatmapInfo beatmap, CancellationToken cancellation)
|
||||||
{
|
{
|
||||||
if (cancellation.IsCancellationRequested)
|
cancellation.ThrowIfCancellationRequested();
|
||||||
return;
|
|
||||||
|
|
||||||
if (api?.State != APIState.Online)
|
if (api?.State != APIState.Online)
|
||||||
return;
|
return;
|
||||||
|
@ -361,6 +361,10 @@ namespace osu.Game.Database
|
|||||||
|
|
||||||
Logger.Log($"Import of {item} successfully completed!", LoggingTarget.Database);
|
Logger.Log($"Import of {item} successfully completed!", LoggingTarget.Database);
|
||||||
}
|
}
|
||||||
|
catch (TaskCanceledException)
|
||||||
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Logger.Error(e, $"Import of {item} failed and has been rolled back.", LoggingTarget.Database);
|
Logger.Error(e, $"Import of {item} failed and has been rolled back.", LoggingTarget.Database);
|
||||||
|
Loading…
Reference in New Issue
Block a user