Community moderators have prevented the ability to post new answers.
The problem is in the error message - your code does not define myIssue.
You either need to define an issue in your code, or, as I suspect it's running in the context of an issue already, try just using the issue context itself (replace myIssue with just issue)
Atlassian University Live webinars provide you and your teams with the chance to strengthen your Atlassian product skills, and learn directly from Atlassian experts. Explore how to enhance...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events