seems to work now
better method to find latest events, faster now