fix double events in plugins