Updated example with new notification handling