While loop not working during multiple conditions

I have added 2 snapshot of SA, first one is working fine, but second is entering into infinite loop. Multi conditions in while loop not working
2 3

it needs to be AND otherwise it will always evaluate to true because when apistatus is set to ‘SUCCESS’

‘SUCCESS’ != ‘PENDING’

apistatus != 'SUCCESS' && apistatus != 'PENDING'