Use ValueTask instead of Task where possible

This commit is contained in:
Alexey Golub 2020-07-18 15:57:51 +03:00
parent ac64d9943a
commit ba66b52fa4
16 changed files with 52 additions and 51 deletions

View file

@ -23,7 +23,7 @@ namespace DiscordChatExporter.Gui.Services
_settingsService = settingsService;
}
public async Task<Version?> CheckForUpdatesAsync()
public async ValueTask<Version?> CheckForUpdatesAsync()
{
if (!_settingsService.IsAutoUpdateEnabled)
return null;
@ -32,7 +32,7 @@ namespace DiscordChatExporter.Gui.Services
return check.CanUpdate ? check.LastVersion : null;
}
public async Task PrepareUpdateAsync(Version version)
public async ValueTask PrepareUpdateAsync(Version version)
{
if (!_settingsService.IsAutoUpdateEnabled)
return;