Hello community, I am needing help creating an automation.
Context:
- I have the following workflow, I need to add a conditional in the automation that allows me to transition from the "TAKING EXAM" state to the state marked with the letter C or D

- The condition must be: if the issue passed through state B at some point in the workflow, then transition to state D
Is there any JQL search or smart value to apply that condition?
Note: the conditional is already configured in the WORKFLOW, but I need to specify it in an automation.
I have the automation set up as follows, but I am open to reading your opinions:

Thank you very much in advance for your collaboration.