Changed the unread message code