mirror of
https://github.com/osukey/osukey.git
synced 2025-05-30 01:47:30 +09:00
Remove async from Import method
This commit is contained in:
parent
99f1a94797
commit
f1f03dd541
@ -246,7 +246,7 @@ namespace osu.Game.Database
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="archive">The archive to be imported.</param>
|
/// <param name="archive">The archive to be imported.</param>
|
||||||
/// <param name="cancellationToken">An optional cancellation token.</param>
|
/// <param name="cancellationToken">An optional cancellation token.</param>
|
||||||
public async Task<TModel> Import(ArchiveReader archive, CancellationToken cancellationToken = default)
|
public Task<TModel> Import(ArchiveReader archive, CancellationToken cancellationToken = default)
|
||||||
{
|
{
|
||||||
cancellationToken.ThrowIfCancellationRequested();
|
cancellationToken.ThrowIfCancellationRequested();
|
||||||
|
|
||||||
@ -256,7 +256,7 @@ namespace osu.Game.Database
|
|||||||
{
|
{
|
||||||
model = CreateModel(archive);
|
model = CreateModel(archive);
|
||||||
|
|
||||||
if (model == null) return null;
|
if (model == null) return Task.FromResult<TModel>(null);
|
||||||
|
|
||||||
model.Hash = computeHash(archive);
|
model.Hash = computeHash(archive);
|
||||||
}
|
}
|
||||||
@ -270,7 +270,7 @@ namespace osu.Game.Database
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
return await Import(model, archive, cancellationToken);
|
return Import(model, archive, cancellationToken);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user