added option parameter is cleared to getmessage for clearing messages if not required