add before and after middlewares
Release 0.6.2