动态编辑Jira问题以使用jira-connector nodejs模块添加修订版本

时间:2018-06-03 19:08:26

标签: json node.js api jira jira-rest-api

我在节点JS中使用jira-connector与API通信,但我似乎无法编辑问题。我一直收到“遗失ID或密钥”错误。这是我的JSON:

    static char MostCommonLetter(string s, out int maxOccurrance)
    {
        int[] occurrances = new int[255];
        for (int i = 0; i < s.Length; i++)
        {
            if (char.IsLetter(s[i]))
            {
                int ascii = (int)s[i];
                occurrances[ascii]++;
            }
        }

        maxOccurrance = occurrances.Max();
        char maxValue = (char)Array.IndexOf(occurrances, maxOccurrance);

        return maxValue;
    }

    //...

    // In C# 7 and above you can call it like that
    var c = MostCommonLetter("abccd", out int maxOccurrance);

    //// In older version of C# you should just declare out variable before use it
    //int maxOccurrance;
    //var c = MostCommonLetter("abccd", out maxOccurrance);

任何可能出错的想法?感谢

0 个答案:

没有答案