Adding a small example of how the quitting event works