fixed where alert msg gets generated, and cleaned up genEventMsg