'Delete list of UIDs from status cache
This function uses sqlites executemany() function which is
much faster than iterating through deletemessage() when we have
many messages to delete.'

def deletemessages(self, uidlist):

    uidlist = [uid for uid in uidlist if (uid in self.messagelist)]
    if (not len(uidlist)):
        return
    self.__sql_write('DELETE    FROM    status    WHERE    id=?', list(zip(uidlist)), True)
    for uid in uidlist:
        del self.messagelist[uid]
