Some minor changes and clean up