Add sorting to messages
Merge pull request #20 from VMBindraban/hotfix/getmessages

Add sorting to messages