namespace OliverBooth.Middleware; internal static class RssEndpointExtensions { public static IEndpointConventionBuilder MapRssFeed(this IEndpointRouteBuilder endpoints, string pattern) { RequestDelegate pipeline = endpoints.CreateApplicationBuilder() .UseMiddleware() .Build(); return endpoints.Map(pattern, pipeline).WithDisplayName("RSS Feed"); } }