Working refactored code, but not 'production ready'