General Cleanup and fixes