private void DisplayHandler_FaviconChanged(string uri) { Task.Run(() => { var request = new HttpRequestMessage(HttpMethod.Head, uri); var response = httpClient.SendAsync(request).ContinueWith(task => { if (task.IsCompleted && task.Result.IsSuccessStatusCode) { Icon = new BrowserIconResource(uri); IconChanged?.Invoke(Icon); window.UpdateIcon(Icon); } }); }); }