search members by ID :D

This commit is contained in:
Emily 2021-03-07 00:16:47 +11:00
parent 9e556e4666
commit eec9fca10f

View file

@ -135,6 +135,15 @@ class Functions {
return; return;
} }
async validateUserID (guild, ID) {
const valid = /[0-9]{18}/.test(ID);
if (valid === true) {
const member = await this.getMember(guild, ID);
if (member) return member;
}
}
async clean (text) { async clean (text) {
if (text && text.constructor.name === 'Promise') { if (text && text.constructor.name === 'Promise') {
text = await text; text = await text;