mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-04-28 05:33:10 +08:00
fix(proxy): enable gzip compression for non-streaming proxy requests
Non-streaming requests were forced to use `Accept-Encoding: identity`, preventing upstream response compression and increasing bandwidth usage. Now only streaming requests conservatively keep `identity` to avoid decompression errors on interrupted SSE streams. Non-streaming requests let reqwest auto-negotiate gzip and transparently decompress responses.
This commit is contained in:
@@ -38,7 +38,7 @@ tauri-plugin-deep-link = "2"
|
||||
dirs = "5.0"
|
||||
toml = "0.8"
|
||||
toml_edit = "0.22"
|
||||
reqwest = { version = "0.12", features = ["rustls-tls", "json", "stream", "socks"] }
|
||||
reqwest = { version = "0.12", features = ["rustls-tls", "json", "stream", "socks", "gzip"] }
|
||||
tokio = { version = "1", features = ["macros", "rt-multi-thread", "time", "sync"] }
|
||||
futures = "0.3"
|
||||
async-stream = "0.3"
|
||||
|
||||
Reference in New Issue
Block a user