Refactor out extraneous variable