Case:
Issue 1 from project A and issue 2 from project B
I created a script listener on on project A with Issue link created trigger. (script does not matter in this case)
When linking an issue 2 to issue 1 with link type issue 2 "causes" issue 1 the script triggers, all good here, but when I try adding a condition which tries to filter the link based on direction and project key, the script no longer triggers.
Here's a list of conditions I tried to use (they are valid conditions).
1. issue.links.filter(L => L.type.inward.includes("is caused by") && L.inwardIssue.key.match('^(A)')).length > 0
2. issue.changelogs[0].items.filter(L => L.field == "Link" && L.toString.includes("This issue is caused by A")) != null
Note, I also tried working around this by using Issue Updated and Issue Updated + Link created.
I am running out if ideas, please help
Earning the Mindful Member badge proves you know how to lead with kindness, plus it enters you into a giveaway for exclusive Atlassian swag. Take the quiz, grab the badge, and comment on our announcement article to spread the good vibes!
Start here