couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From iil...@apache.org
Subject [45/50] couch-httpd commit: updated refs/heads/split_out_httpd_stack to e44a372
Date Tue, 01 Mar 2016 20:01:18 GMT
Use cors_config for 'credentials' setting

The 'credentials' setting should be configurable per vhost.

COUCHDB-2945


Project: http://git-wip-us.apache.org/repos/asf/couchdb-couch-httpd/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-couch-httpd/commit/cfbd7f7b
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-couch-httpd/tree/cfbd7f7b
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-couch-httpd/diff/cfbd7f7b

Branch: refs/heads/split_out_httpd_stack
Commit: cfbd7f7b5551ab4ec759357fe83aa6126f81250f
Parents: 03bd7e3
Author: ILYA Khlopotov <iilyak@ca.ibm.com>
Authored: Tue Feb 16 15:20:40 2016 -0800
Committer: ILYA Khlopotov <iilyak@ca.ibm.com>
Committed: Tue Mar 1 08:35:09 2016 -0800

----------------------------------------------------------------------
 src/couch_httpd_cors.erl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-couch-httpd/blob/cfbd7f7b/src/couch_httpd_cors.erl
----------------------------------------------------------------------
diff --git a/src/couch_httpd_cors.erl b/src/couch_httpd_cors.erl
index b87f5ef..401ad2e 100644
--- a/src/couch_httpd_cors.erl
+++ b/src/couch_httpd_cors.erl
@@ -283,7 +283,7 @@ get_cors_config(#httpd{cors_config = undefined, mochi_req = MochiReq})
->
     Host = couch_httpd_vhost:host(MochiReq),
 
     EnableCors = config:get("httpd", "enable_cors", "false") =:= "true",
-    AllowCredentials = config:get("cors", "credentials", "false") =:= "true",
+    AllowCredentials = cors_config(Host, "credentials", "false") =:= "true",
 
     AllowHeaders = case cors_config(Host, "headers", undefined) of
         undefined ->


Mime
View raw message