Skip to content

Commit b2f26bb

Browse files
authored
Merge pull request #12 from Zickles/feat/commas-levelcommand
Remote Access Trojan
2 parents 4765e93 + 18684a8 commit b2f26bb

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

Cargo.lock

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,3 +47,4 @@ r2d2_sqlite = "0.30.0"
4747
r2d2 = "0.8.10"
4848
wb_sqlite = "0.2.1"
4949
rusqlite = { version = "0.36.0", features = ["bundled"] }
50+
num-format = "0.4.4"

src/commands/level.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
use std::sync::Arc;
44

5+
use num_format::{Locale, ToFormattedString};
56
use serde_rusqlite::{from_row, from_rows};
67
use tokio::sync::Mutex;
78

@@ -70,7 +71,7 @@ pub async fn level(
7071
"Level: {}, position: {}\nXP: {xp_earned}/{xp_to_next_level}\n{bar}\nSocial Credit: {}",
7172
user.level,
7273
pos.unwrap_or_default() + 1,
73-
user.social_credit,
74+
user.social_credit.to_formatted_string(&Locale::en),
7475
);
7576
tracing::info!("Level {message}");
7677
ctx.interaction_client

0 commit comments

Comments
 (0)