Cleanup and minimal fix