extractor_middleware
Converts an extractor into a middleware so it can be run for many routes without having to repeat it in the function signature.