Minor correction in event handling

The editor change events were not getting captured because of a bug.
Corrected.