small refactor, plus better naming