Code cleanup/harmonization