membphis commented on a change in pull request #840: feature: allow set up 
header to client in proxy-rewrite,CROS allowed
URL: https://github.com/apache/incubator-apisix/pull/840#discussion_r345015119
 
 

 ##########
 File path: lua/apisix/plugins/proxy-rewrite.lua
 ##########
 @@ -110,6 +115,18 @@ function _M.rewrite(conf, ctx)
     end
 end
 
+function _M.header_filter(conf, ctx)
+    if ngx.status >= 300 then
+        return
+    end
+
+    if conf.resp_headers then
+        for header_name, header_value in pairs(conf.resp_headers) do
 
 Review comment:
   Yes, that is better.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to