Fix bugs regarding the new message system