This commit is contained in:
March 7th
2022-03-31 20:21:53 +07:00
parent 9edf3ccda2
commit 8734b87ea9
3 changed files with 3 additions and 1 deletions

View File

@@ -174,6 +174,7 @@ class ClientUser extends User {
* @returns {Promise}
*/
setDiscriminator(discriminator, password) {
if (!this.nitro) throw new Error('You must be a Nitro User to change your discriminator.');
if (!password && !this.client.password)
throw new Error('A password is required to change a discriminator.');
return this.edit({