add anonymous middleware