plugins/mod_http.lua
changeset 13144 7a6874f9fd40
parent 13131 f45a29b32f7a
child 13145 451cb119026e
equal deleted inserted replaced
13141:b417a49cc31b 13144:7a6874f9fd40
   113 	end
   113 	end
   114 	return "http://disabled.invalid/";
   114 	return "http://disabled.invalid/";
   115 end
   115 end
   116 
   116 
   117 local function header_set_tostring(header_value)
   117 local function header_set_tostring(header_value)
   118 	return array(pairs(header_value._items)):concat(", ");
   118 	return array(header_value:items()):concat(", ");
   119 end
   119 end
   120 
   120 
   121 local function apply_cors_headers(response, methods, headers, max_age, allow_credentials, allowed_origins, origin)
   121 local function apply_cors_headers(response, methods, headers, max_age, allow_credentials, allowed_origins, origin)
   122 	if allowed_origins and not allowed_origins[origin] then
   122 	if allowed_origins and not allowed_origins[origin] then
   123 		return;
   123 		return;