Better storage of lists
Changed id to string value
Better error handling
Minor fixes