Updated event handler registration