From: Eugen Rochko Date: Wed, 15 Feb 2017 22:26:17 +0000 (+0100) Subject: Expose Link headers via CORS X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=ff4964913077530d7a6696b6ffe0d4d51fafdc3d;p=mastodon.git Expose Link headers via CORS --- diff --git a/config/application.rb b/config/application.rb index d44835957..8da5ade3c 100644 --- a/config/application.rb +++ b/config/application.rb @@ -34,7 +34,7 @@ module Mastodon allow do origins '*' - resource '/api/*', headers: :any, methods: [:post, :put, :delete, :get, :options], credentials: false + resource '/api/*', headers: :any, methods: [:post, :put, :delete, :get, :options], credentials: false, expose: ['Link', 'X-RateLimit-Reset', 'X-RateLimit-Limit', 'X-RateLimit-Remaining', 'X-Request-Id'] resource '/oauth/token', headers: :any, methods: [:post], credentials: false end end