fix mail UID indexing for non-sequential uids