Minor code simplifying