Cleaned up error handling
Added TODOs section, cleanup