Proper error handling.