Perform code refactoring #1
- fixed all points except Events