Fixed some overzealous refactoring