cleaned up the data structure