How to set expression for Until activity in Azure Data Factory? - String does not match

I'm trying to execute Azure Durable Function in ADF. I have "Get Current Function Status" Activity inside Until activity. Possible value are pending, completed, running and exception.

I wish to execute Until runtimeStatus Completed or Exception is reached. It this possible to do following way or should I create flag variable?

I try to set expression, but getting warning "String does not match" :

or(equals(activity('Get Current Function Status').output.runtimeStatus,'Pending'),
equals(activity('Get Current Function Status').output.runtimeStatus,'Running'))

enter image description here


Solution 1:

Can you try the below expression, there are few tweaks.

@or(equals(activity('Azure Function').output.runtimeStatus,'Pending'),equals(activity('Azure Function').output.runtimeStatus,'Running'))

enter image description here