Skip to content

Commit

Permalink
Update reqwest, cleanup json Value usage
Browse files Browse the repository at this point in the history
  • Loading branch information
novacrazy committed Mar 20, 2024
1 parent a7b9db9 commit e9ba517
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 14 deletions.
15 changes: 5 additions & 10 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ rkyv = { version = "0.7", optional = true, features = ["validation", "smol_str",
bytecheck = { version = "0.6", optional = true }

serde = { version = "1", features = ["derive", "rc"] }
serde_json = "1"
bitflags = "2"
serde_repr = "0.1"
enum-primitive-derive = "0.3"
Expand All @@ -58,6 +57,8 @@ ahash = { version = "0.8", optional = true }
# Maybe?
# typescript-definitions = { git = "https://github.com/storyscript/typescript-definitions" }

serde_json = { version = "1", optional = true }

postgres-types = { version = "0.2.1", optional = true }
bytes = { version = "1", optional = true }
rusqlite = { version = "0.31.0", optional = true }
Expand All @@ -77,6 +78,7 @@ percent-encoding = { version = "2.1.0", optional = true }
arc-swap = { version = "1.5", optional = true }
base64 = { version = "0.22.0", optional = true }
tokio = { version = "1", optional = true, default_features = false, features = ["io-util"] }
reqwest = { version = "0.12", optional = true, default_features = false, features = ["gzip", "deflate", "http2"] }

tokio-tungstenite = { version = "0.21", optional = true, default_features = false, features = ["connect"] }
miniz_oxide = { version = "0.7", optional = true }
Expand All @@ -85,13 +87,6 @@ pin-project-lite = { version = "0.2.8", optional = true }
async-trait = { version = "0.1", optional = true }
smallvec = { version = "1.10.0", optional = true }

[dependencies.reqwest]
git = "https://github.com/seanmonstar/reqwest"
branch = "0.12-dev"
optional = true
default_features = false
features = ["gzip", "deflate", "http2"]

[features]
_internal_common = ["thiserror"]

Expand All @@ -105,7 +100,7 @@ rusqlite = ["dep:rusqlite", "common/rusqlite", "timestamp/rusqlite", "snowflake/
api = ["http", "_internal_common", "percent-encoding", "futures"] # http required for Method

# Low-level command execution
driver = ["reqwest", "api", "serde_urlencoded", "form_urlencoded", "headers", "mime", "url", "base64", "crc32fast", "bytes", "lazy_static"]
driver = ["serde_json", "reqwest", "api", "serde_urlencoded", "form_urlencoded", "headers", "mime", "url", "base64", "crc32fast", "bytes", "lazy_static"]

# High-level client library
client = ["driver", "arc-swap", "tokio"]
Expand All @@ -114,7 +109,7 @@ fs = ["tokio/fs"]
brotli = ["reqwest?/brotli"]

# Realtime gateway support
gateway = ["tokio-tungstenite", "miniz_oxide", "futures", "pin-project-lite", "_internal_common"]
gateway = ["serde_json", "tokio-tungstenite", "miniz_oxide", "futures", "pin-project-lite", "_internal_common"]

framework_utils = ["smallvec"]
framework = ["client", "gateway", "async-trait", "tokio/macros", "framework_utils"]
Expand Down
2 changes: 0 additions & 2 deletions src/models/party/prefs.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
use std::collections::HashMap;
use std::fmt;

use serde_json::Value;

use super::*;

use crate::models::Locale;
Expand Down
2 changes: 0 additions & 2 deletions src/models/user/prefs.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
use std::collections::HashMap;
use std::fmt;

use serde_json::Value;

use super::*;

common::enum_codes! {
Expand Down

0 comments on commit e9ba517

Please sign in to comment.