Fixed birthday checking updated j_db
This commit is contained in:
4 files changed
+9
-12
No files matched your search
@@ -78,16 +78,13 @@ pub async fn list_birthdays(ctx: &Context, msg: &Message) -> CommandResult {
|
||||
|
||||
msg_builder.push_bold_line("All the birthdays I know:");
|
||||
for birthday in birthdays {
|
||||
let guild = msg.guild(&ctx.cache).unwrap();
|
||||
|
||||
let member = guild
|
||||
.members
|
||||
.get(&UserId::from(birthday.discord_id))
|
||||
.unwrap();
|
||||
|
||||
let user_id = UserId::from(birthday.discord_id);
|
||||
|
||||
let user = user_id.to_user(&ctx.http).await?;
|
||||
|
||||
msg_builder.push_line(format!(
|
||||
"* {} {}",
|
||||
member.display_name(),
|
||||
user.name,
|
||||
birthday.birthday.format("%m-%d-%Y")
|
||||
));
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user