fix event polling