Improved error handling in the "create" operations.