getMailsInfo improvements

I just learned how upstream works. It's okay now.