Refactoring maybe