Event bug fix

Apparently prototype was being overwritten