Minor coderefactoring