Refactoring + added test of online/offline events