lostisland / faraday_middleware

Various Faraday middlewares for Faraday-based API wrappers
MIT License
557 stars 203 forks source link

Brotli as an optional dependency for Gzip #186

Closed PChambino closed 5 years ago

PChambino commented 5 years ago

Issue: #185

The current implementation doesn't really make brotli optional and the middleware will fail if it is missing and the server replies with brotli encoding.

This PR should make it optional but with the current specs it is a bit difficult to test it.

optional_dependency could be moved to Faraday::Middleware if it makes sense later.

This is just a possible solution. :)