Refactor to address golint errors & warnings