I have similar code where I would like to use polling.
What doesnt make sense how you are in first example
branching on result if await makes code flow synchronous,
so if-else in async block should be called after returning result from
asynchronous fn().
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I have similar code where I would like to use polling.
What doesnt make sense how you are in first example
branching on result if await makes code flow synchronous,
so if-else in async block should be called after returning result from
asynchronous fn().