How to avoid try/catch statements nesting/chaining in JavaScript ?