fix strange code WeakEvent