mirror of
https://github.com/KingDuckZ/kamokan.git
synced 2024-11-23 00:33:44 +00:00
Case-insensitive check for HTTPS=on.
This commit is contained in:
parent
adcfc75f97
commit
d3319512f4
1 changed files with 4 additions and 1 deletions
|
@ -166,7 +166,10 @@ namespace cgi {
|
|||
}
|
||||
|
||||
bool Env::https() const {
|
||||
return m_cgi_env[CGIVars::HTTPS] == "on";
|
||||
const std::string& val = m_cgi_env[CGIVars::HTTPS];
|
||||
return val.size() == 2 and (
|
||||
val == "on" or val == "ON" or val == "oN" or val == "On"
|
||||
);
|
||||
}
|
||||
|
||||
uint16_t Env::server_port() const {
|
||||
|
|
Loading…
Reference in a new issue