use string.empty instead of null

This commit is contained in:
弘韬 张 2021-01-07 11:20:14 +08:00
parent a4edbc2cb9
commit f72b716fb4

View file

@ -113,7 +113,7 @@ namespace Flow.Launcher.Infrastructure.Http
Log.Debug($"|Http.Get|Url <{url}>");
using var response = await client.GetAsync(url, token);
if (token.IsCancellationRequested)
return null;
return string.Empty;
var content = await response.Content.ReadAsStringAsync();
if (response.StatusCode == HttpStatusCode.OK)
{