fix for enter event clearing messages

fix for bug