Minor code enhancements and clean-up.