changed the way of doing replay of message