Add try-catch to JavaScript AST