Discord-Net-Labs / Discord.Net-Labs

An experimental fork of Discord.Net that implements the newest discord features for testing and development to eventually get merged into Discord.Net
https://labs.discordnet.dev
MIT License
156 stars 42 forks source link

Add the ability to get user by name/discrim #290

Closed SylveonDeko closed 2 years ago

SylveonDeko commented 2 years ago

I feel like this will be useful in cases where you aren't able to get the ID of a member, for example a reason in audit logs that just says the username, for example in my bot it says when banning: Sylveon#0001 | reason here

quinchs commented 2 years ago

This isn't possible if the user isn't in a guild.

If they are in a guild you can use SearchUsersAsync("user#1234").