nghttpx: Simplify
We only change req_.upgrade_request once, so just using else is suffice.
This commit is contained in:
parent
f8472f4709
commit
3c7038dfe1
|
@ -677,9 +677,7 @@ void Downstream::inspect_http2_request() {
|
||||||
void Downstream::inspect_http1_request() {
|
void Downstream::inspect_http1_request() {
|
||||||
if (req_.method == HTTP_CONNECT) {
|
if (req_.method == HTTP_CONNECT) {
|
||||||
req_.upgrade_request = true;
|
req_.upgrade_request = true;
|
||||||
}
|
} else {
|
||||||
|
|
||||||
if (!req_.upgrade_request) {
|
|
||||||
auto upgrade = req_.fs.header(http2::HD_UPGRADE);
|
auto upgrade = req_.fs.header(http2::HD_UPGRADE);
|
||||||
if (upgrade) {
|
if (upgrade) {
|
||||||
const auto &val = upgrade->value;
|
const auto &val = upgrade->value;
|
||||||
|
|
Loading…
Reference in New Issue