diff --git a/include/opendht/http.h b/include/opendht/http.h index 1d4362d7..b982f16f 100644 --- a/include/opendht/http.h +++ b/include/opendht/http.h @@ -200,18 +200,18 @@ constexpr const restinio::http_method_id_t method_encrypt{HTTP_ENCRYPT, "ENCRYPT struct custom_http_methods_t { - static constexpr restinio::http_method_id_t from_nodejs(int m) noexcept { - if(m == method_listen.raw_id()) - return method_listen; - else if(m == method_stats.raw_id()) - return method_stats; - else if(m == method_sign.raw_id()) - return method_sign; - else if(m == method_encrypt.raw_id()) - return method_encrypt; - else - return restinio::default_http_methods_t::from_nodejs(m); - } + static constexpr restinio::http_method_id_t from_nodejs(int m) noexcept { + if(m == method_listen.raw_id()) + return method_listen; + else if(m == method_stats.raw_id()) + return method_stats; + else if(m == method_sign.raw_id()) + return method_sign; + else if(m == method_encrypt.raw_id()) + return method_encrypt; + else + return restinio::default_http_methods_t::from_nodejs(m); + } }; } // namespace restinio