Hi there Atlassian Community...
A few years back I had used the following in the 'Condition and Configuration' field to send a custom email (Jira v8.5.1 and SR v184.108.40.206-p5):
def rendererManager = ComponentAccessor.getComponent(RendererManager)
def issue = ComponentAccessor.issueManager.getIssueByCurrentKey(issue.key)
def wikiRenderer = rendererManager.getRendererForType("atlassian-wiki-renderer")
def renderContext = new IssueRenderContext(issue)
config.deschHTML = wikiRenderer.render(issue.description, renderContext)
I'm now attempting on creating a custom email using the info I had before, and am getting a warning on the def issue line.
"Variable "issue" masks a binding variable of the same name. Please choose a different name for variable: "issue" @line 11, column 5."
Does anyone know what this should be and/or why this isn't working any longer? I've tried making several updates based on things I was able to find in the community, but nothing is working.
Currently running most recent versions of both Jira and ScriptRunner.
@Ravi Sagar _Adaptavist_ sorry, still not following. This is how the email post function is set up ....I've placed the line in the only spot it can go. This was working on an earlier version (I used the exact same format)...but it's not working now and giving me a warning.
When I try and run it to preview, I get this:
Catch up with Atlassian Product Managers in our 2020 Demo Den round-up! From Advanced Roadmaps to Code in Jira to Next-Gen Workflows, check out the videos below to help up-level your work in the new ...
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