refactored events