How to avoid error "Status: closed prevents ticket update"

Originally asked by ben friedman on 18 November 2020 (original question)


Hi,

i have a sync between ZD and JSD.

some tickets in ZD are getting to ‘closed’ status. on ZD, both incoming and outgoing are set with

if (issue.status == “closed”){
return
}

(not sure its needed, since it doesnt seem to work and was only added after i got the error).

what can i do to avoid the error from appearing?


Answer by Juan Grases on 19 November 2020

Hi! Could you try:

if (issue.status?.name == "closed"){
  return
}

If that doesn’t work. You will need to also check the remote status (replica.status.name is not the one that would close your zendesk ticket.

if (issue.status?.name == "closed" || replica.status.name == "Closed"){
  return
}

Use the right status name for the replica status.


Answer by Mariia Onyshchenko on 19 November 2020

Hi ben friedman
This article should help you https://docs.idalko.com/exalate/display/ED/isIssueEditable

Best,
Mariia


Comments:

Juan Grases commented on 19 November 2020

Unfortunately this only works for Jira Cloud