Fixed some stuff
parent
43b787abc0
commit
cf0bb51c1f
|
@ -117,7 +117,7 @@ export default class Util {
|
||||||
|
|
||||||
public randomPassword(): string {
|
public randomPassword(): string {
|
||||||
let tempPass = ''; const passChars = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '1', '2', '3', '4', '5', '6', '7', '8', '9', '0'];
|
let tempPass = ''; const passChars = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '1', '2', '3', '4', '5', '6', '7', '8', '9', '0'];
|
||||||
tempPass += passChars[Math.floor(Math.random() * passChars.length)];
|
while (tempPass.length < 5) { tempPass += passChars[Math.floor(Math.random() * passChars.length)]; }
|
||||||
return tempPass;
|
return tempPass;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -119,7 +119,7 @@ export default class CreateAccount extends Command {
|
||||||
+ 'You may now return to Modmail, and continue setting up your account from there.\n\n'
|
+ 'You may now return to Modmail, and continue setting up your account from there.\n\n'
|
||||||
+ 'An email containing some useful information has also been sent').catch();
|
+ 'An email containing some useful information has also been sent').catch();
|
||||||
|
|
||||||
return confirmation.edit(`${this.client.stores.emojis.success} ***Account successfully created***\n**Username:** \`${args[3]}\`\n**Temporary Password:** \`${tempPass}\``);
|
return confirmation.edit(`${this.client.stores.emojis.success} ***Account successfully created***\n**Username:** \`${args[2]}\`\n**Temporary Password:** \`${tempPass}\``);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
return this.client.util.handleError(error, message, this);
|
return this.client.util.handleError(error, message, this);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue