fixed bug in getMessageColor