Slight cleanup and fixes