Spelling mistake.
More error handling and logging.
Removed debug output.