fix message index layout