Example #1
0
        public bool DoesJiraExist(string jiraRef)
        {
            try
            {
                CheckAndConnectJira();
                var issue = GetJiraIssue(jiraRef);
                if (issue != null)
                {
                    return(true);
                }
            }
            catch (Exception)
            {
                recentJiraCollection.Remove(jiraRef);
                return(false);
            }

            recentJiraCollection.Remove(jiraRef);
            return(false);
        }
Example #2
0
        public bool DoesJiraExist(string jiraRef)
        {
            try
            {
                CheckAndConnectJira();
                var issues = jira.GetIssuesFromJql($"key = \"{jiraRef}\"").ToList();

                if (issues.Any())
                {
                    recentJiraCollection.AddRecentJiras(issues);
                    return(true);
                }
                else
                {
                    recentJiraCollection.Remove(jiraRef);
                    return(false);
                }
            }
            catch (Exception)
            {
                recentJiraCollection.Remove(jiraRef);
                return(false);
            }
        }