Better Error Handling in CommonJS