fixed issue with double biding of event handlers