Setup refactoring

Refactoring the setup further, to be on par with the changes from yesterdays pul request.