error with refactor. commit to fix error