Fix error from refactoring