Skip to content

Commit

Permalink
Apply formatting, add to rank ) and align stars left
Browse files Browse the repository at this point in the history
  • Loading branch information
jgadelange authored Dec 18, 2024
1 parent 18c387e commit cf9631f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,12 @@ async fn leaderboard_today(ctx: Context<'_>) -> Result<(), Error> {
stars += "*";
}

format!("{2:>5} | {name:0$} | {stars:^5} | {1:>5}", start_width, x.score, i+1)
format!(
"{2:>4}) | {name:0$} | {stars:<5} | {1:>5}",
start_width,
x.score,
i + 1
)
})
.collect::<Vec<String>>()
.as_mut(),
Expand Down

0 comments on commit cf9631f

Please sign in to comment.