security patch

merge-requests/1/merge
Bsian 2019-10-30 20:38:11 +00:00
parent b6ccfaa8a6
commit c95ecd3aa3
No known key found for this signature in database
GPG Key ID: 097FB9A291026091
1 changed files with 5 additions and 8 deletions

View File

@ -32,19 +32,16 @@ export default class Eval extends Command {
evaled = error.stack; evaled = error.stack;
} }
/* evaled = evaled.replace(RegExp(this.client.config.prefix, 'gi'), 'juul');
if (output) { evaled = evaled.replace(RegExp(this.client.config.emailPass, 'gi'), 'juul');
output = output.replace(RegExp(this.client.config.prefix, 'gi'), 'juul'); evaled = evaled.replace(RegExp(this.client.config.cloudflare, 'gi'), 'juul');
output = output.replace(RegExp(this.client.config.emailPass, 'gi'), 'juul');
output = output.replace(RegExp(this.client.config.cloudflare, 'gi'), 'juul');
}
*/
const display = this.client.util.splitString(evaled, 1975); const display = this.client.util.splitString(evaled, 1975);
if (display[5]) { if (display[5]) {
try { try {
const { data } = await axios.post('https://snippets.cloud.libraryofcode.org/documents', display.join('')); const { data } = await axios.post('https://snippets.cloud.libraryofcode.org/documents', display.join(''));
return message.channel.createMessage(`${this.client.stores.emojis.success} Your evaluation output can be found on https://snippets.cloud.libraryofcode.org/${data.key}`); return message.channel.createMessage(`${this.client.stores.emojis.success} Your evaluation evaled can be found on https://snippets.cloud.libraryofcode.org/${data.key}`);
} catch (error) { } catch (error) {
return message.channel.createMessage(`${this.client.stores.emojis.error} ${error}`); return message.channel.createMessage(`${this.client.stores.emojis.error} ${error}`);
} }