Fix leaderboard users after mixup during poise port

late-submissions
Elnu 2 years ago
parent a45b51b010
commit 37d808eab3

@ -370,7 +370,7 @@ pub async fn leaderboard(ctx: &PrefixContext<'_>) -> Result<(), Error> {
let mut leaderboard_html = String::from("<table id=\"leaderboard\">");
for (i, (id, count)) in top_submitters[0..LENGTH].iter().enumerate() {
let place = i + 1;
let user = &ctx.msg.author;
let user = serenity::UserId(id.parse::<u64>().unwrap()).to_user(&ctx.discord.http).await?;
let avatar = get_avatar(&user);
let profile = format!("https://discord.com/users/{id}");
let name = &user.name;

Loading…
Cancel
Save