Fixing doctrine refactoring related issue