Skip to content

Commit

Permalink
chore: support CN endpoints 2
Browse files Browse the repository at this point in the history
  • Loading branch information
sunli829 committed Dec 14, 2023
1 parent be4df67 commit 9e1613e
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions rust/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,18 @@ impl Config {
) -> Self {
Self {
http_cli_config: HttpClientConfig::new(app_key, app_secret, access_token),
quote_ws_url: QUOTE_WS_URL.to_string(),
trade_ws_url: TRADE_WS_URL.to_string(),
quote_ws_url: if is_cn() {
CN_QUOTE_WS_URL
} else {
QUOTE_WS_URL
}
.to_string(),
trade_ws_url: if is_cn() {
CN_TRADE_WS_URL
} else {
TRADE_WS_URL
}
.to_string(),
language: Language::EN,
}
}
Expand Down

0 comments on commit 9e1613e

Please sign in to comment.