refactored 1.2