Originally asked by Samuel Carter on 18 May 2022 (original question)
I’ve been trying to get User Picker (single user) syncing successfully between two instances of Jira, and Jira Service Desk. This is a User Picker field, and both instances have the exact same users on each, and the same custom field ‘Responsible Guild’. Please see below for incoming/outgoing scripts:
Outgoing (JSM):
replica.customFields."Responsible Guild" = issue.customFields."Responsible Guild"
Incoming (Jira):
issue.customFields."Responsible Guild".value = replica.customFields."Responsible Guild"?.value.username
When this is run, we get an error on the incoming script ‘Cannot get property ‘username’ on null object’ and it cites this line:
issue.customFields."Responsible Guild".value = replica.customFields."Responsible Guild"?.value.username
Unsure on where I’m going wrong, or what I need to do to get this working.