Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

ngx.req.get_headers()["xxxx"] return nil #210

Closed
baoming opened this Issue · 3 comments

2 participants

@baoming

Problem:
request with addition header xxxx return nil

Howto reproduce:

  1. a.lua
local xcdomain = ngx.req.get_headers()["xxxx"]
ngx.log(ngx.ERR, xcdomain)               --this will see a nil in nginx error.log
  1. ```nginx.conf header_filter_by_lua_file conf/dhgate.lua;

@agentzh
Owner
  1. Which version of ngx_lua are you using? If you're not using the latest, then try upgrading.
  2. Are you sure you have that particular request header in your request? Could you provide a more complete example that can reproduce this issue?
@agentzh
Owner

@baoming Any updates on this issue please?

@baoming

With more debug figure out that it is not an issue. in my case, there is a Upercase header name look like "Xxxx", and my lua code use "Xxxx" too. when change it to "xxxx" everything works well.
@agentzh

@baoming baoming closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.