refactoring events#index