updates code refactor error message