remove prefix for middleware