@@ -1674,7 +1674,8 @@ class decompressor {
16741674
16751675 // 15 is the value of wbits, which should be at the maximum possible value
16761676 // to ensure that any gzip stream can be decoded. The offset of 32 specifies
1677- // that the stream type should be automatically detected either gzip or deflate.
1677+ // that the stream type should be automatically detected either gzip or
1678+ // deflate.
16781679 is_valid_ = inflateInit2 (&strm, 32 + 15 ) == Z_OK;
16791680 }
16801681
@@ -1874,8 +1875,8 @@ bool read_content(Stream &strm, T &x, size_t payload_max_length, int &status,
18741875 decompressor decompressor;
18751876
18761877 std::string content_encoding = x.get_header_value (" Content-Encoding" );
1877- if (content_encoding.find (" gzip" ) != std::string::npos
1878- || content_encoding.find (" deflate" ) != std::string::npos) {
1878+ if (content_encoding.find (" gzip" ) != std::string::npos ||
1879+ content_encoding.find (" deflate" ) != std::string::npos) {
18791880 if (!decompressor.is_valid ()) {
18801881 status = 500 ;
18811882 return false ;
@@ -4125,11 +4126,9 @@ Client::Post(const char *path, const Headers &headers, size_t content_length,
41254126 content_type);
41264127}
41274128
4128-
41294129inline std::shared_ptr<Response>
41304130Client::Post (const char *path, const Headers &headers, const Params ¶ms) {
4131- std::string query = detail::params_to_query_str (params);
4132-
4131+ auto query = detail::params_to_query_str (params);
41334132 return Post (path, headers, query, " application/x-www-form-urlencoded" );
41344133}
41354134
@@ -4201,8 +4200,7 @@ inline std::shared_ptr<Response> Client::Put(const char *path,
42014200
42024201inline std::shared_ptr<Response>
42034202Client::Put (const char *path, const Headers &headers, const Params ¶ms) {
4204- std::string query = detail::params_to_query_str (params);
4205-
4203+ auto query = detail::params_to_query_str (params);
42064204 return Put (path, headers, query, " application/x-www-form-urlencoded" );
42074205}
42084206
0 commit comments