Refactoring WordController