mirror of
https://github.com/KingDuckZ/kamokan.git
synced 2025-08-03 12:50:02 +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 {
|
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 {
|
uint16_t Env::server_port() const {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue