Fixing the viewed and resolved functions on messages