events callback fix.