Hi,
I'm trying to validate a custom filed that is a user multi-picker. I want to send an email to the people specified in that field but there is always a chance that a user will put there a person that is not meant to see that email.
So what I want to do is to check if users picked in that custom filed are members of one specific group.
Maybe I'm not searching carefully enough but I cannot find any solution.
So far i have managed to do this (not much considering this is a tutorial part mostly):
!!issue.customfield_15206 && issue.customfield_15206.some(it => it.groups == "team_name")
What I've learned is tht the second part is always false as te "it" object has no attribute groups.
Is there any way to achieve that? Or should I change the approach? Jira Automation maybe?