fix two typos in message storing code