Add debug statement and add text check between message sent and message received