khrt / Raisin

Raisin - a REST API micro framework for Perl 🐫 🐪
61 stars 30 forks source link

Respect content-type from `provides` route annotations #50

Closed slobo closed 5 years ago

slobo commented 5 years ago

Formatter middleware now respects provides annotation for routes and uses it both as default and as a restriction on allowed response content types.

This makes it possible to for ex. output binary blobs on specific paths, while keeping the rest of the paths as structured data.

To acheive this, we needed to make the following changes:

khrt commented 5 years ago

Thanks for the merge request!