Implementation of latest messages sync when joining a room