Clean up code, update CHANGELOG and README