move broccoli-middleware into module