Unfortunately, you're absolutely correct.
Plz note that the SVN trunk version of that code will not throw an exception when finding a custom issue priority. It is juts a temporary workaround: it is still not able to work with custom priorities, but will not crash, either.
Plz post a feature request to our JIRA if you need that feature.
Thanks Aron. I'll post a feature request as it's important to me to get this information.
OK, Rob, your request is welcome in our JIRA.