private static async Task RemoveTags(List <Issue> taggedIssues, List <Issue> list, IIssuesService issuesService) { Console.WriteLine($"Removing tags {ourConfig.TagForHotIssues} from {taggedIssues.Count} issues"); foreach (var issue in taggedIssues.Where(issue1 => !list.Contains(issue1))) { Console.Write("."); try { await issuesService.RemoveTag(issue, ourConfig.TagForHotIssues); } catch (YouTrackErrorException) { Console.WriteLine($"Failed to remove tag silently ${ourConfig.TagForHotIssues} from ${issue.Id}"); await issuesService.RemoveTag(issue, ourConfig.TagForHotIssues, false); } } Console.WriteLine("Finished."); }
private static async Task RemoveTags(List <Issue> taggedIssues, List <Issue> list, IIssuesService issuesService) { Console.WriteLine($"Removing tags {ourConfig.TagForHotIssues} from {taggedIssues.Count} issues"); foreach (var issue in taggedIssues.Where(issue1 => !list.Contains(issue1))) { Console.Write("."); await issuesService.RemoveTag(issue, ourConfig.TagForHotIssues); } Console.WriteLine("Finished."); }