Refactoring the main bundle