refactored outline