Answer would be
Option 4 because in function
processing our error is async in nature. Traditional
try/catch blocks doesn't catch async errors in the promise chain because of their sync nature. You might say they work in case of
async/await syntax. Yes, they work because when we are using
await keyword then we are kind of suspending the execution of the function till promised is resolved so it behaves in a sync manner.
To understand better and checkout more tutorials, checkout -- https://bit.ly/devtools-yv