Hi Supun,
so far, I have found out that when the problem happens, we see in the JSON output (via Firebug) that _displayMessage is empty. Maybe something is wrong is the passing of the message parameter from function to function. I'll continue my research tomorrow, but of course try to find out why this happens to _displayMessage.