]> cat aescling's git repositories - mastodon.git/commitdiff
add `patch` method support to CORS (#2408)
authorShin Adachi <shn@glucose.jp>
Mon, 24 Apr 2017 18:19:51 +0000 (03:19 +0900)
committerEugen <eugen@zeonfederated.com>
Mon, 24 Apr 2017 18:19:51 +0000 (20:19 +0200)
config/application.rb

index 3db8558dea043c784b34fb7e739d35806add7804..dddc3e4fb768731b645d1874339ddc8ef1e158db 100644 (file)
@@ -64,7 +64,7 @@ module Mastodon
       allow do
         origins  '*'
 
-        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 '/api/*',       headers: :any, methods: [:post, :put, :delete, :get, :patch, :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