Fixed refactor mistake