Config: apply CorsResourcePolicy to PUT requests
PUT requests are part of the public upsert API, so if postgrest runs at a different origin, these requests will fail because they don't pass CORS.
This commit is contained in:
committed by
Steve Chávez
parent
5bfb68b982
commit
2da6bd6d1c
@@ -82,7 +82,7 @@ data AppConfig = AppConfig {
|
||||
|
||||
defaultCorsPolicy :: CorsResourcePolicy
|
||||
defaultCorsPolicy = CorsResourcePolicy Nothing
|
||||
["GET", "POST", "PATCH", "DELETE", "OPTIONS"] ["Authorization"] Nothing
|
||||
["GET", "POST", "PATCH", "PUT", "DELETE", "OPTIONS"] ["Authorization"] Nothing
|
||||
(Just $ 60*60*24) False False True
|
||||
|
||||
-- | CORS policy to be used in by Wai Cors middleware
|
||||
|
||||
Reference in New Issue
Block a user