Rename functions, and fix error handling